blob: 8ae95b95564f81c4807697a8597026437329728c [file] [log] [blame]
Jeremy Ronquillo223db002020-06-05 10:28:22 -07001{{/*
Jeremy Ronquilloec2d3e42020-06-05 11:33:39 -07002# Copyright 2019-present Open Networking Foundation
Jeremy Ronquillo223db002020-06-05 10:28:22 -07003
Jeremy Ronquillo6046ce32020-06-18 11:06:29 -07004# SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0
Jeremy Ronquillo223db002020-06-05 10:28:22 -07005*/}}
6
Hyunsun Moon83ff7352020-07-09 11:03:52 -07007{{- if .Values.config.mme.deploy }}
Jeremy Ronquillo223db002020-06-05 10:28:22 -07008{{- $configJson := index .Values.config.mme.cfgFiles "config.json" }}
9{{- $configJsonS11 := index $configJson "s11" }}
10{{- $configJsonS1ap := index $configJson "s1ap" }}
11---
12apiVersion: v1
13kind: Service
14metadata:
15 name: mme
16 labels:
17{{ tuple "mme" . | include "omec-control-plane.metadata_labels" | indent 4 }}
18spec:
19 selector:
20{{ tuple "mme" . | include "omec-control-plane.metadata_labels" | indent 4 }}
21 type: ClusterIP
22 ports:
23 - name: s11
24 port: {{ index $configJsonS11 "egtp_default_port" }}
25 protocol: UDP
26 - name: s6a
27 port: 3868
28 protocol: TCP
29 - name: s1ap
30 port: {{ index $configJsonS1ap "sctp_port" }}
31 protocol: SCTP
Hyunsun Moon11d24f92020-08-26 14:55:19 -070032 - name: prometheus-exporter
33 port: {{ .Values.config.mme.prometheus.port }}
Jeremy Ronquillo223db002020-06-05 10:28:22 -070034 protocol: TCP
Ajay Lotan Thakurefe5d8e2021-07-31 08:32:16 -050035 - name: mme-app-config
36 port: 8080
37 protocol: TCP
38 - name: mme-s1ap-config
39 port: 8081
40 protocol: TCP
Jeremy Ronquillo223db002020-06-05 10:28:22 -070041---
42apiVersion: v1
43kind: Service
44metadata:
45 name: mme-headless
46 labels:
47{{ tuple "mme" . | include "omec-control-plane.metadata_labels" | indent 4 }}
48spec:
49 selector:
50{{ tuple "mme" . | include "omec-control-plane.metadata_labels" | indent 4 }}
51 clusterIP: None
52 ports:
53 - name: s11
54 port: {{ index $configJsonS11 "egtp_default_port" }}
55 protocol: UDP
56 - name: s6a
57 port: 3868
58 protocol: TCP
59 - name: s1ap
60 port: {{ index $configJsonS1ap "sctp_port" }}
61 protocol: SCTP
62---
63apiVersion: v1
64kind: Service
65metadata:
66 name: mme-external
67 labels:
68{{ tuple "mme" . | include "omec-control-plane.metadata_labels" | indent 4 }}
69spec:
70 selector:
71{{ tuple "mme" . | include "omec-control-plane.metadata_labels" | indent 4 }}
72 type: NodePort
73 ports:
Hyunsun Moon11d24f92020-08-26 14:55:19 -070074 {{- if .Values.config.mme.prometheus.nodePort.enabled }}
75 - name: prometheus-exporter
76 port: {{ .Values.config.mme.prometheus.port }}
77 protocol: TCP
78 nodePort: {{ .Values.config.mme.prometheus.nodePort.port }}
79 {{- end }}
Jeremy Ronquillo223db002020-06-05 10:28:22 -070080 {{- if .Values.config.mme.s11.nodePort.enabled }}
81 - name: s11
82 port: {{ index $configJsonS11 "egtp_default_port" }}
83 protocol: UDP
84 nodePort: {{ .Values.config.mme.s11.nodePort.port }}
85 {{- end }}
86 {{- if .Values.config.mme.s6a.nodePort.enabled }}
87 - name: s6a
88 port: 3868
89 protocol: TCP
90 nodePort: {{ .Values.config.mme.s6a.nodePort.port }}
91 {{- end }}
92 - name: s1ap
93 port: {{ index $configJsonS1ap "sctp_port" }}
94 nodePort: {{ index $configJsonS1ap "sctp_port_external" }}
95 protocol: SCTP
Hyunsun Moon83ff7352020-07-09 11:03:52 -070096{{- end }}