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: |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 20 | - name: s11 |
| 21 | port: {{ .Values.config.spgwc.s11.port }} |
| 22 | protocol: UDP |
Hyunsun Moon | 7f03a77 | 2020-09-27 23:23:50 -0500 | [diff] [blame] | 23 | - name: pfcp |
| 24 | port: {{ .Values.config.spgwc.n4.port }} |
| 25 | protocol: UDP |
Hyunsun Moon | 11d24f9 | 2020-08-26 14:55:19 -0700 | [diff] [blame] | 26 | - name: prometheus-exporter |
| 27 | port: {{ .Values.config.spgwc.prometheus.port }} |
| 28 | protocol: TCP |
Hyunsun Moon | 7f03a77 | 2020-09-27 23:23:50 -0500 | [diff] [blame] | 29 | - name: rest |
| 30 | port: {{ .Values.config.spgwc.rest.port }} |
Ajay Lotan Thakur | 97278fa | 2020-09-21 17:31:51 -0500 | [diff] [blame] | 31 | protocol: TCP |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 32 | --- |
| 33 | apiVersion: v1 |
| 34 | kind: Service |
| 35 | metadata: |
| 36 | name: spgwc-headless |
| 37 | labels: |
| 38 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 39 | spec: |
| 40 | clusterIP: None |
| 41 | selector: |
| 42 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
Hyunsun Moon | 7f03a77 | 2020-09-27 23:23:50 -0500 | [diff] [blame] | 43 | {{- if or .Values.config.spgwc.s11.nodePort.enabled .Values.config.spgwc.n4.nodePort.enabled .Values.config.spgwc.prometheus.nodePort.enabled .Values.config.spgwc.rest.nodePort.enabled }} |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 44 | --- |
| 45 | apiVersion: v1 |
| 46 | kind: Service |
| 47 | metadata: |
| 48 | name: spgwc-external |
| 49 | labels: |
| 50 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 51 | spec: |
| 52 | type: NodePort |
| 53 | selector: |
| 54 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 55 | ports: |
Hyunsun Moon | 7f03a77 | 2020-09-27 23:23:50 -0500 | [diff] [blame] | 56 | {{- if .Values.config.spgwc.s11.nodePort.enabled }} |
| 57 | - name: s11 |
| 58 | port: {{ .Values.config.spgwc.s11.port }} |
| 59 | protocol: UDP |
| 60 | nodePort: {{ .Values.config.spgwc.s11.nodePort.port }} |
| 61 | {{- end }} |
| 62 | {{- if .Values.config.spgwc.n4.nodePort.enabled }} |
| 63 | - name: pfcp |
| 64 | port: {{ .Values.config.spgwc.n4.port }} |
| 65 | protocol: UDP |
| 66 | nodePort: {{ .Values.config.spgwc.n4.nodePort.port }} |
| 67 | {{- end }} |
Hyunsun Moon | 11d24f9 | 2020-08-26 14:55:19 -0700 | [diff] [blame] | 68 | {{- if .Values.config.spgwc.prometheus.nodePort.enabled }} |
| 69 | - name: prometheus-exporter |
| 70 | port: {{ .Values.config.spgwc.prometheus.port }} |
| 71 | protocol: TCP |
| 72 | nodePort: {{ .Values.config.spgwc.prometheus.nodePort.port }} |
| 73 | {{- end }} |
Hyunsun Moon | 7f03a77 | 2020-09-27 23:23:50 -0500 | [diff] [blame] | 74 | {{- if .Values.config.spgwc.rest.nodePort.enabled }} |
| 75 | - name: rest |
| 76 | port: {{ .Values.config.spgwc.rest.port }} |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 77 | protocol: TCP |
Hyunsun Moon | 7f03a77 | 2020-09-27 23:23:50 -0500 | [diff] [blame] | 78 | nodePort: {{ .Values.config.spgwc.rest.nodePort.port }} |
Jeremy Ronquillo | 223db00 | 2020-06-05 10:28:22 -0700 | [diff] [blame] | 79 | {{- end }} |
| 80 | {{- end }} |
Hyunsun Moon | 83ff735 | 2020-07-09 11:03:52 -0700 | [diff] [blame] | 81 | {{- end }} |