projects
/
osm
/
N2VC.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix 1539: Add --skip-repo option for Helm
[osm/N2VC.git]
/
n2vc
/
k8s_helm3_conn.py
diff --git
a/n2vc/k8s_helm3_conn.py
b/n2vc/k8s_helm3_conn.py
index
06e5788
..
404485f
100644
(file)
--- a/
n2vc/k8s_helm3_conn.py
+++ b/
n2vc/k8s_helm3_conn.py
@@
-42,7
+42,6
@@
class K8sHelm3Connector(K8sHelmBaseConnector):
helm_command: str = "/usr/bin/helm3",
log: object = None,
on_update_db=None,
helm_command: str = "/usr/bin/helm3",
log: object = None,
on_update_db=None,
- vca_config: dict = None,
):
"""
Initializes helm connector for helm v3
):
"""
Initializes helm connector for helm v3
@@
-64,7
+63,6
@@
class K8sHelm3Connector(K8sHelmBaseConnector):
kubectl_command=kubectl_command,
helm_command=helm_command,
on_update_db=on_update_db,
kubectl_command=kubectl_command,
helm_command=helm_command,
on_update_db=on_update_db,
- vca_config=vca_config,
)
self.log.info("K8S Helm3 connector initialized")
)
self.log.info("K8S Helm3 connector initialized")
@@
-300,12
+298,8
@@
class K8sHelm3Connector(K8sHelmBaseConnector):
# If default repo is not included add
cluster_uuid = "{}:{}".format(namespace, cluster_id)
repo_list = await self.repo_list(cluster_uuid)
# If default repo is not included add
cluster_uuid = "{}:{}".format(namespace, cluster_id)
repo_list = await self.repo_list(cluster_uuid)
- for repo in repo_list:
- self.log.debug("repo")
- if repo["name"] == "stable":
- self.log.debug("Default repo already present")
- break
- else:
+ stable_repo = [repo for repo in repo_list if repo["name"] == "stable"]
+ if not stable_repo and self._stable_repo_url:
await self.repo_add(cluster_uuid, "stable", self._stable_repo_url)
# Returns False as no software needs to be uninstalled
await self.repo_add(cluster_uuid, "stable", self._stable_repo_url)
# Returns False as no software needs to be uninstalled