Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 1 | {{/* |
Jeremy Ronquillo | ec2d3e4 | 2020-06-05 11:33:39 -0700 | [diff] [blame] | 2 | # Copyright 2019-present Open Networking Foundation |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 3 | |
Jeremy Ronquillo | 6046ce3 | 2020-06-18 11:06:29 -0700 | [diff] [blame] | 4 | # SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0 |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 5 | */}} |
| 6 | |
Hyunsun Moon | 83ff735 | 2020-07-09 11:03:52 -0700 | [diff] [blame] | 7 | {{- if .Values.config.spgwc.deploy }} |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 8 | --- |
| 9 | apiVersion: v1 |
| 10 | kind: Service |
| 11 | metadata: |
| 12 | name: spgwc |
| 13 | labels: |
| 14 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 15 | spec: |
| 16 | type: ClusterIP |
| 17 | selector: |
| 18 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 19 | ports: |
| 20 | - name: cp-comm |
| 21 | port: {{ .Values.config.spgwc.cpComm.port }} |
| 22 | {{- if .Values.config.spgwc.multiUpfs }} |
| 23 | protocol: TCP |
| 24 | {{- else }} |
| 25 | protocol: UDP |
| 26 | {{- end }} |
| 27 | - name: s11 |
| 28 | port: {{ .Values.config.spgwc.s11.port }} |
| 29 | protocol: UDP |
| 30 | --- |
| 31 | apiVersion: v1 |
| 32 | kind: Service |
| 33 | metadata: |
| 34 | name: spgwc-headless |
| 35 | labels: |
| 36 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 37 | spec: |
| 38 | clusterIP: None |
| 39 | selector: |
| 40 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 41 | ports: |
| 42 | - name: cp-comm |
| 43 | port: {{ .Values.config.spgwc.cpComm.port }} |
| 44 | {{- if .Values.config.spgwc.multiUpfs }} |
| 45 | protocol: TCP |
| 46 | {{- else }} |
| 47 | protocol: UDP |
| 48 | {{- end }} |
| 49 | - name: s11 |
| 50 | port: {{ .Values.config.spgwc.s11.port }} |
| 51 | protocol: UDP |
| 52 | {{- if not .Values.config.spgwc.multiUpfs }} |
| 53 | {{- if or .Values.config.spgwc.cpComm.nodePort.enabled .Values.config.spgwc.s11.nodePort.enabled }} |
| 54 | --- |
| 55 | apiVersion: v1 |
| 56 | kind: Service |
| 57 | metadata: |
| 58 | name: spgwc-external |
| 59 | labels: |
| 60 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 61 | spec: |
| 62 | type: NodePort |
| 63 | selector: |
| 64 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 65 | ports: |
| 66 | {{- if .Values.config.spgwc.cpComm.nodePort.enabled }} |
| 67 | - name: cp-comm |
| 68 | port: {{ .Values.config.spgwc.cpComm.port }} |
| 69 | protocol: TCP |
| 70 | {{- end }} |
| 71 | {{- if .Values.config.spgwc.s11.nodePort.enabled }} |
| 72 | - name: s11 |
| 73 | port: {{ .Values.config.spgwc.s11.port }} |
| 74 | protocol: UDP |
| 75 | {{- end }} |
| 76 | {{- end }} |
| 77 | {{- end }} |
Hyunsun Moon | 83ff735 | 2020-07-09 11:03:52 -0700 | [diff] [blame] | 78 | {{- end }} |