diff options
-rw-r--r-- | kubernetes/sdnc/templates/service.yaml | 56 | ||||
-rw-r--r-- | kubernetes/sdnc/values.yaml | 3 |
2 files changed, 34 insertions, 25 deletions
diff --git a/kubernetes/sdnc/templates/service.yaml b/kubernetes/sdnc/templates/service.yaml index c5577a1cdb..0bbda1a364 100644 --- a/kubernetes/sdnc/templates/service.yaml +++ b/kubernetes/sdnc/templates/service.yaml @@ -35,33 +35,45 @@ metadata: } ]' spec: - type: {{ .Values.service.type }} + type: NodePort ports: - {{if eq .Values.service.type "NodePort" -}} - - port: {{ .Values.service.externalPort }} - targetPort: {{ .Values.service.internalPort }} + - name: "{{ .Values.service.portName }}-restconf" {{ if not .Values.global.aafEnabled }} - nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort4 }} - {{ end }} - name: "{{ .Values.service.portName }}-8282" - - port: {{ .Values.service.externalPort2 }} - targetPort: {{ .Values.service.internalPort2 }} - name: "{{ .Values.service.portName }}-8202" - - port: {{ .Values.service.externalPort3 }} - targetPort: {{ .Values.service.internalPort3 }} - nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort3 }} - name: "{{ .Values.service.portName }}-8280" - - port: {{ .Values.service.externalPort4 }} + port: {{ .Values.service.externalPort }} + targetPort: {{ .Values.service.internalPort }} + {{- else -}} + port: {{ .Values.service.externalPort4 }} targetPort: {{ .Values.service.internalPort4 }} - {{ if .Values.global.aafEnabled }} - nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort4 }} {{ end }} - name: "{{ .Values.service.portName }}-8443" - {{- else -}} - - port: {{ .Values.service.externalPort }} + nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort4 }} + selector: + app: {{ include "common.name" . }} + release: {{ include "common.release" . }} +--- +apiVersion: v1 +kind: Service +metadata: + name: "{{ .Values.service.name }}-oam" + namespace: {{ include "common.namespace" . }} + labels: + app: {{ include "common.name" . }} + chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }} + release: {{ include "common.release" . }} + heritage: {{ .Release.Service }} +spec: + type: ClusterIP + ports: + - name: "{{ .Values.service.portName }}-restconf-alt" + {{ if .Values.global.aafEnabled }} + port: {{ .Values.service.externalPort }} targetPort: {{ .Values.service.internalPort }} - name: {{ .Values.service.portName }} - {{- end}} + {{- else -}} + port: {{ .Values.service.internalPort4 }} + target: {{ .Values.service.internalPort4 }} + {{ end }} + - name: "{{ .Values.service.portName }}-karaf" + port: {{ .Values.service.externalPort2 }} + targetPort: {{ .Values.service.internalPort2 }} selector: app: {{ include "common.name" . }} release: {{ include "common.release" . }} diff --git a/kubernetes/sdnc/values.yaml b/kubernetes/sdnc/values.yaml index 8fd7590863..8ef043a5c1 100644 --- a/kubernetes/sdnc/values.yaml +++ b/kubernetes/sdnc/values.yaml @@ -306,13 +306,10 @@ service: #port externalPort: 8282 - nodePort: "02" externalPort2: 8202 - nodePort2: "08" externalPort3: 8280 - nodePort3: 46 externalPort4: 8443 nodePort4: 67 |