From: wrider Date: Fri, 12 Jul 2019 02:40:30 +0000 (-0400) Subject: Update rtmgr chart X-Git-Tag: 0.0.2~65 X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=commitdiff_plain;h=35f4069bf0175d1c03bb3a9ce7fc35ef5fd9397f;p=it%2Fdep.git Update rtmgr chart Change-Id: Ida0d29c50d7683ab57739898bef05db6b37fb154 Signed-off-by: wrider --- diff --git a/ric-common/Common-Template/helm/ric-common/templates/_name.tpl b/ric-common/Common-Template/helm/ric-common/templates/_name.tpl index f86bc241..9ad9ffac 100644 --- a/ric-common/Common-Template/helm/ric-common/templates/_name.tpl +++ b/ric-common/Common-Template/helm/ric-common/templates/_name.tpl @@ -138,6 +138,30 @@ +{{- define "common.name.submgr" -}} + {{- if .Values.submgr -}} + {{- if .Values.submgr.nameOverride -}} + {{- printf "%s" .Values.submgr.nameOverride -}} + {{- else -}} + {{- printf "submgr" -}} + {{- end -}} + {{- else -}} + {{- printf "submgr" -}} + {{- end -}} +{{- end -}} + + +{{- define "common.fullname.submgr" -}} + {{- $name := ( include "common.name.submgr" . ) -}} + {{- $namespace := ( include "common.namespace.platform" . ) -}} + {{- printf "%s-%s" $namespace $name | trunc 63 | trimSuffix "-" -}} +{{- end -}} + + + + + + {{- define "common.name.a1mediator" -}} {{- if .Values.a1mediator -}} {{- if .Values.a1mediator.nameOverride -}} diff --git a/ric-common/Common-Template/helm/ric-common/templates/_servicename.tpl b/ric-common/Common-Template/helm/ric-common/templates/_servicename.tpl index e4e337fb..b480cec7 100644 --- a/ric-common/Common-Template/helm/ric-common/templates/_servicename.tpl +++ b/ric-common/Common-Template/helm/ric-common/templates/_servicename.tpl @@ -50,6 +50,11 @@ {{- printf "service-%s-rmr" $name | trunc 63 | trimSuffix "-" -}} {{- end -}} +{{- define "common.servicename.submgr.rmr" -}} + {{- $name := ( include "common.fullname.submgr" . ) -}} + {{- printf "service-%s-rmr" $name | trunc 63 | trimSuffix "-" -}} +{{- end -}} + {{- define "common.servicename.a1mediator.rmr" -}} {{- $name := ( include "common.fullname.a1mediator" . ) -}} {{- printf "service-%s-rmr" $name | trunc 63 | trimSuffix "-" -}} diff --git a/ric-platform/50-RIC-Platform/helm/rtmgr/templates/config.yaml b/ric-platform/50-RIC-Platform/helm/rtmgr/templates/config.yaml new file mode 100644 index 00000000..9cd05fa3 --- /dev/null +++ b/ric-platform/50-RIC-Platform/helm/rtmgr/templates/config.yaml @@ -0,0 +1,51 @@ +# +#================================================================================== +# Copyright (c) 2019 AT&T Intellectual Property. +# Copyright (c) 2019 Nokia +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +#================================================================================== +# +# +# Abstract: Configuration values for the routing manager +# Date: 29 May 2019 +# +apiVersion: v1 +kind: ConfigMap +metadata: + name: {{ include "common.configmapname.rtmgr" . }}-rtmgrcfg +data: + # FQDN and port info of the platform components for routing manager to form + # and distribute corresponding routes to them + rtmgrcfg: | + { + "PlatformComponents": + [ + { + "name": "E2TERM", + "fqdn": "{{ include "common.servicename.e2term.rmr" . }}", + "port": 4561 + }, + { + "name": "SUBMAN", + "fqdn": "{{ include "common.servicename.submgr.rmr" . }}", + "port": 4561 + }, + { + "name": "E2MAN", + "fqdn": "{{ include "common.servicename.e2mgr.rmr" . }}", + "port": 4561 + } + ] + } + diff --git a/ric-platform/50-RIC-Platform/helm/rtmgr/templates/deployment.yaml b/ric-platform/50-RIC-Platform/helm/rtmgr/templates/deployment.yaml index 66cef2f5..fd930045 100644 --- a/ric-platform/50-RIC-Platform/helm/rtmgr/templates/deployment.yaml +++ b/ric-platform/50-RIC-Platform/helm/rtmgr/templates/deployment.yaml @@ -45,11 +45,25 @@ spec: image: {{ include "common.repository" . }}/{{ .Values.rtmgr.image.name }}:{{ .Values.rtmgr.image.tag }} imagePullPolicy: {{ include "common.pullPolicy" . }} command: ["/run_rtmgr.sh"] + #command: ["/bin/sh"] + #args: ["-c", "while true; do echo hello; sleep 10;done"] envFrom: - configMapRef: name: {{ include "common.configmapname.rtmgr" . }}-env + volumeMounts: + - mountPath: /cfg + name: rtmgrcfg + readOnly: true ports: - name: "rmrroute" containerPort: {{ .Values.rtmgr.service.rmr.route.port }} - name: "rmrdata" containerPort: {{ .Values.rtmgr.service.rmr.data.port }} + volumes: + - name: "rtmgrcfg" + configMap: + name: {{ include "common.configmapname.rtmgr" . }}-rtmgrcfg + items: + - key: rtmgrcfg + path: rtmgr-config.json + mode: 0644 diff --git a/ric-platform/50-RIC-Platform/helm/rtmgr/templates/env.yaml b/ric-platform/50-RIC-Platform/helm/rtmgr/templates/env.yaml index 6ef54bc4..2f6ab6a0 100644 --- a/ric-platform/50-RIC-Platform/helm/rtmgr/templates/env.yaml +++ b/ric-platform/50-RIC-Platform/helm/rtmgr/templates/env.yaml @@ -1,4 +1,4 @@ -################################################################################ +############################################################################### # Copyright (c) 2019 AT&T Intellectual Property. # # Copyright (c) 2019 Nokia. # # # @@ -25,9 +25,12 @@ data: DBAAS_PORT_6379_TCP_PORT: "6379" RMR_RTG_SVC: "{{ .Values.rtmgr.service.rmr.route.port }}" XMURL: "http://{{ include "common.servicename.appmgr.http" . }}:8080/ric/v1/xapps" - SOCKET: "tcp://0.0.0.0:4560" RTFILE: "/db/rt.json" - NBI: "httpGetter" - SBI: "nngpub" - RPE: "rmr" - SDL: "file" + CFGFILE: "/cfg/rtmgr-config.json" + RPE: "{{ .Values.rtmgr.rpe }}" + SBI: "{{ .Values.rtmgr.sbi }}" + SBIURL: "{{ .Values.rtmgr.sbiurl }}" + NBI: "{{ .Values.rtmgr.nbi }}" + NBIURL: "{{ .Values.rtmgr.nbiurl }}" + LOGLEVEL: "{{ .Values.rtmgr.loglevel }}" + diff --git a/ric-platform/50-RIC-Platform/helm/rtmgr/values.yaml b/ric-platform/50-RIC-Platform/helm/rtmgr/values.yaml index fd1b0774..904a5971 100644 --- a/ric-platform/50-RIC-Platform/helm/rtmgr/values.yaml +++ b/ric-platform/50-RIC-Platform/helm/rtmgr/values.yaml @@ -45,3 +45,11 @@ rtmgr: port: 4561 data: port: 4560 + + rpe: rmrpush + sbi: nngpush + sbiurl: 0.0.0.0 + nbi: httpRESTful + nbiurl: http://0.0.0.0:8888 + loglevel: DEBUG +