Use the common mongodb URL in PCF config
Change-Id: I20a4c1a9302ef6c2188b6f382c753c7ef2783069
diff --git a/omec/5g-control-plane/templates/configmap-pcf.yaml b/omec/5g-control-plane/templates/configmap-pcf.yaml
index 0e3a7a3..dcb9bfe 100644
--- a/omec/5g-control-plane/templates/configmap-pcf.yaml
+++ b/omec/5g-control-plane/templates/configmap-pcf.yaml
@@ -9,6 +9,7 @@
{{- if not .Values.config.useExistingConfigMap -}}
{{- $pcfcfg := index .Values.config.pcf.cfgFiles "pcfcfg.conf" }}
{{- $sbi := index $pcfcfg.configuration "sbi" }}
+{{- $config := index $pcfcfg "configuration" }}
{{- if not (hasKey $pcfcfg "logger") -}}
{{- $_ := .Values.config.logger | set $pcfcfg "logger" -}}
@@ -17,6 +18,10 @@
{{- if not (hasKey $sbi "port") -}}
{{- $_ := .Values.config.pcf.sbi.port | set $sbi "port" -}}
{{- end }}
+
+{{- if not (hasKey $config "mongodb") -}}
+{{- $_ := dict "name" .Values.config.mongodb.name "url" .Values.config.mongodb.url | set $config "mongodb" -}}
+{{- end }}
{{- end }}
---