blob: 1fcf9aed924d2846b089371a9548ec1167e93b2d [file] [log] [blame]
{{/*
# Copyright 2020-present Open Networking Foundation
# SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0
*/}}
{{- if .Values.config.udm.deploy }}
{{- $udmcfg := index .Values.config.udm.cfgFiles "udmcfg.conf" }}
{{- $sbi := index $udmcfg.configuration "sbi" }}
{{- if not (hasKey $sbi "registerIPv4") -}}
{{- $_ := "POD_IP" | set $sbi "registerIPv4" -}}
{{- end }}
{{- if not (hasKey $sbi "bindingIPv4") -}}
{{- $_ := "POD_IP" | set $sbi "bindingIPv4" -}}
{{- end }}
{{- if not (hasKey $sbi "port") -}}
{{- $_ := .Values.config.udm.sbi.port | set $sbi "port" -}}
{{- end }}
---
apiVersion: v1
kind: ConfigMap
metadata:
name: udm
labels:
{{ tuple "udm" . | include "5g-control-plane.metadata_labels" | indent 4 }}
data:
udm-run.sh: |
{{ tuple "bin/_udm-run.sh.tpl" . | include "5g-control-plane.template" | indent 4 }}
{{- range $key, $value := .Values.config.udm.cfgFiles }}
{{ $key }}: |-
{{ toYaml $value | indent 4 }}
{{- end }}
{{- end }}