)
# sync fs
- self.fs.reverse_sync(from_path=cluster_uuid)
+ self.fs.reverse_sync(from_path=cluster_id)
- async def repo_update(self, cluster_uuid: str, name: str, repo_type: str = "chart"):
+ async def repo_update(self, cluster_id: str, name: str, repo_type: str = "chart"):
self.log.debug(
- "Cluster {}, updating {} repository {}".format(
- cluster_uuid, repo_type, name
- )
+ "Cluster {}, updating {} repository {}".format(cluster_id, repo_type, name)
)
# init_env
paths, env = self._init_paths_env(
- cluster_name=cluster_uuid, create_if_not_exist=True
+ cluster_name=cluster_id, create_if_not_exist=True
)
# sync local dir
- self.fs.sync(from_path=cluster_uuid)
+ self.fs.sync(from_path=cluster_id)
# helm repo update
command = "{} repo update {}".format(self._helm_command, name)
)
# sync fs
- self.fs.reverse_sync(from_path=cluster_uuid)
+ self.fs.reverse_sync(from_path=cluster_id)
async def repo_list(self, cluster_uuid: str) -> list:
"""
repo = self._split_repo(kdu_model)
if repo:
- self.repo_update(cluster_uuid, repo)
+ self.repo_update(cluster_id, repo)
command = self._get_upgrade_command(
kdu_model,
self.helm_conn.fs.sync.assert_called_once_with(from_path=self.cluster_id)
self.helm_conn.fs.reverse_sync.assert_called_once_with(
- from_path=self.cluster_uuid
+ from_path=self.cluster_id
)
self.assertEqual(
self.helm_conn._local_async_exec.call_count,
self.helm_conn.fs.sync.assert_called_once_with(from_path=self.cluster_id)
self.helm_conn.fs.reverse_sync.assert_called_once_with(
- from_path=self.cluster_uuid
+ from_path=self.cluster_id
)
self.assertEqual(
self.helm_conn._local_async_exec.call_count,