Commit 83c7a4bf authored by harshavardhan.c's avatar harshavardhan.c

enh: changed the mysql branch push to client name.

parent fe62e06e
...@@ -56,7 +56,7 @@ def push_helm_deployments(repo_link: str, private_token: str, branch: str, final ...@@ -56,7 +56,7 @@ def push_helm_deployments(repo_link: str, private_token: str, branch: str, final
for file in files_list: for file in files_list:
_action = { _action = {
'action': 'update', 'action': 'update',
'file_path': os.path.join(HELM_PATH, file), 'file_path': f"{HELM_PATH}/{file}",
'content': open(f'{final_helm_path}/{file}').read() 'content': open(f'{final_helm_path}/{file}').read()
} }
commit_actions.append(_action) commit_actions.append(_action)
...@@ -195,7 +195,8 @@ if __name__ == '__main__': ...@@ -195,7 +195,8 @@ if __name__ == '__main__':
helm_out_file_path=helm_out_file_path, helm_out_file_path=helm_out_file_path,
global_config_data=global_config_data, global_config_data=global_config_data,
module_name=_file.split(".yml")[0]) module_name=_file.split(".yml")[0])
push_helm_deployments(helm_repo, git_access_token, _branch, final_helm_path=OUTPUT_PATH, base_path=helm_path) push_helm_deployments(helm_repo, git_access_token, _client_name, final_helm_path=OUTPUT_PATH,
base_path=helm_path)
except Exception as e: except Exception as e:
logging.exception(f"Exception Occurred while processing the Helm-Script Preparation {e.args}") logging.exception(f"Exception Occurred while processing the Helm-Script Preparation {e.args}")
...@@ -203,3 +204,4 @@ if __name__ == '__main__': ...@@ -203,3 +204,4 @@ if __name__ == '__main__':
# shutil.rmtree(HELM_STORE_PATH) # shutil.rmtree(HELM_STORE_PATH)
shutil.rmtree(HELM_TEMP_PATH) shutil.rmtree(HELM_TEMP_PATH)
shutil.rmtree(GENERAL_TEMP_PATH) shutil.rmtree(GENERAL_TEMP_PATH)
shutil.rmtree(OUTPUT_PATH)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment