Set default namespace for KSU kustomizations to flux-system
Change-Id: I6643b9271f0e389ced44940eeabdf3d25acd3af0
Signed-off-by: garciadeblas <gerardo.garciadeblas@telefonica.com>
diff --git a/osm_lcm/k8s.py b/osm_lcm/k8s.py
index 4440b5a..816eb28 100644
--- a/osm_lcm/k8s.py
+++ b/osm_lcm/k8s.py
@@ -2117,7 +2117,7 @@
oka_list = op_params["oka"]
oka_item = oka_list[0]
oka_params = oka_item.get("transformation", {})
- target_ns = oka_params.get("namespace", "default")
+ kustomization_ns = oka_params.get("kustomization_namespace", "flux-system")
profile_id = op_params.get("profile", {}).get("_id")
profile_type = op_params.get("profile", {}).get("profile_type")
self.logger.info(
@@ -2136,7 +2136,7 @@
{
"item": "kustomization",
"name": kustomization_name,
- "namespace": target_ns,
+ "namespace": kustomization_ns,
"condition": {
"jsonpath_filter": "status.conditions[?(@.type=='Ready')].status",
"value": "True",
@@ -2170,7 +2170,7 @@
oka_list = db_ksu["oka"]
oka_item = oka_list[0]
oka_params = oka_item.get("transformation", {})
- target_ns = oka_params.get("namespace", "default")
+ kustomization_ns = oka_params.get("kustomization_namespace", "flux-system")
profile_id = op_params.get("profile", {}).get("_id")
profile_type = op_params.get("profile", {}).get("profile_type")
self.logger.info(
@@ -2189,7 +2189,7 @@
{
"item": "kustomization",
"name": kustomization_name,
- "namespace": target_ns,
+ "namespace": kustomization_ns,
"deleted": True,
"timeout": self._checkloop_kustomization_timeout,
"enable": True,