blob: bc838ac22f8f98b7b7266c3140d27c4db1316b83 [file] [log] [blame]
Jakub Latusekd8eaff62020-10-21 13:36:29 +02001{{/*
toshrajbhardwajf4fc1c62018-08-06 07:35:14 +00002# Copyright © 2018 ZTE
3# Modifications Copyright © 2018 AT&T, Amdocs, Bell Canada
priyanshua1b061392018-05-29 12:50:14 +05304# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
Jakub Latusekd8eaff62020-10-21 13:36:29 +020015*/}}
priyanshua1b061392018-05-29 12:50:14 +053016
17apiVersion: v1
18kind: Service
19metadata:
20 name: {{ include "common.servicename" . }}
21 namespace: {{ include "common.namespace" . }}
22 labels:
23 app: {{ include "common.name" . }}
24 chart: {{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}
Krzysztof Opasiak137d7cc2020-01-24 23:49:11 +010025 release: {{ include "common.release" . }}
priyanshua1b061392018-05-29 12:50:14 +053026 heritage: {{ .Release.Service }}
priyanshu3af9db62018-08-16 16:23:52 +053027 annotations:
28 msb.onap.org/service-info: '[
29 {
30 "serviceName": "wf-gui",
31 "version": "v1",
32 "url": "/",
33 "protocol": "UI",
IlanaPc80bff92019-11-18 21:10:08 +020034 "port": "{{ .Values.service.internalPort2 }}",
priyanshu3af9db62018-08-16 16:23:52 +053035 "visualRange":"0|1"
36 }
37 ]'
priyanshua1b061392018-05-29 12:50:14 +053038spec:
39 type: {{ .Values.service.type }}
40 ports:
41 {{if eq .Values.service.type "NodePort" -}}
IlanaPc80bff92019-11-18 21:10:08 +020042 - port: {{ template "wfd-fe.internalPort" . }}
priyanshua1b061392018-05-29 12:50:14 +053043 nodePort: {{ .Values.global.nodePortPrefix | default .Values.nodePortPrefix }}{{ .Values.service.nodePort }}
IlanaPc80bff92019-11-18 21:10:08 +020044 name: {{ .Values.service.portName }}
priyanshua1b061392018-05-29 12:50:14 +053045 {{- else -}}
IlanaPc80bff92019-11-18 21:10:08 +020046 - port: {{ if .Values.config.isHttpsEnabled }}{{ .Values.service.externalPort2 }}{{ else }}{{ .Values.service.externalPort }}{{ end }}
47 targetPort: {{ template "wfd-fe.internalPort" . }}
48 name: {{ .Values.service.portName }}
priyanshua1b061392018-05-29 12:50:14 +053049 {{- end}}
50 selector:
51 app: {{ include "common.name" . }}
Krzysztof Opasiak137d7cc2020-01-24 23:49:11 +010052 release: {{ include "common.release" . }}