Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 1 | {{/* |
| 2 | Copyright 2019-present Open Networking Foundation |
| 3 | |
| 4 | 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. |
| 15 | */}} |
| 16 | |
| 17 | --- |
| 18 | apiVersion: v1 |
| 19 | kind: Service |
| 20 | metadata: |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 21 | name: spgwc |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 22 | labels: |
| 23 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 24 | spec: |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 25 | type: ClusterIP |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 26 | selector: |
| 27 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 28 | ports: |
| 29 | - name: cp-comm |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 30 | port: {{ .Values.config.spgwc.cpComm.port }} |
| 31 | {{- if .Values.config.spgwc.multiUpfs }} |
| 32 | protocol: TCP |
| 33 | {{- else }} |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 34 | protocol: UDP |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 35 | {{- end }} |
| 36 | - name: s11 |
| 37 | port: {{ .Values.config.spgwc.s11.port }} |
| 38 | protocol: UDP |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 39 | --- |
| 40 | apiVersion: v1 |
| 41 | kind: Service |
| 42 | metadata: |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 43 | name: spgwc-headless |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 44 | labels: |
| 45 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 46 | spec: |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 47 | clusterIP: None |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 48 | selector: |
| 49 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 50 | ports: |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 51 | - name: cp-comm |
| 52 | port: {{ .Values.config.spgwc.cpComm.port }} |
| 53 | {{- if .Values.config.spgwc.multiUpfs }} |
| 54 | protocol: TCP |
| 55 | {{- else }} |
Hyunsun Moon | 16d7092 | 2019-08-25 04:57:25 -0500 | [diff] [blame] | 56 | protocol: UDP |
Hyunsun Moon | 834c28f | 2019-12-05 18:26:22 -0800 | [diff] [blame] | 57 | {{- end }} |
| 58 | - name: s11 |
| 59 | port: {{ .Values.config.spgwc.s11.port }} |
| 60 | protocol: UDP |
| 61 | {{- if not .Values.config.spgwc.multiUpfs }} |
| 62 | {{- if or .Values.config.spgwc.cpComm.nodePort.enabled .Values.config.spgwc.s11.nodePort.enabled }} |
| 63 | --- |
| 64 | apiVersion: v1 |
| 65 | kind: Service |
| 66 | metadata: |
| 67 | name: spgwc-external |
| 68 | labels: |
| 69 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 70 | spec: |
| 71 | type: NodePort |
| 72 | selector: |
| 73 | {{ tuple "spgwc" . | include "omec-control-plane.metadata_labels" | indent 4 }} |
| 74 | ports: |
| 75 | {{- if .Values.config.spgwc.cpComm.nodePort.enabled }} |
| 76 | - name: cp-comm |
| 77 | port: {{ .Values.config.spgwc.cpComm.port }} |
| 78 | protocol: TCP |
| 79 | {{- end }} |
| 80 | {{- if .Values.config.spgwc.s11.nodePort.enabled }} |
| 81 | - name: s11 |
| 82 | port: {{ .Values.config.spgwc.s11.port }} |
| 83 | protocol: UDP |
| 84 | {{- end }} |
| 85 | {{- end }} |
| 86 | {{- end }} |