update omec-cp helm chart to deploy submon-exporter
Change-Id: I6cb9594360e9ebda46bccb5ac21c5e48fb4cdfad
diff --git a/omec/omec-control-plane/Chart.yaml b/omec/omec-control-plane/Chart.yaml
index 6809d1a..4de8a4e 100644
--- a/omec/omec-control-plane/Chart.yaml
+++ b/omec/omec-control-plane/Chart.yaml
@@ -19,4 +19,4 @@
name: omec-control-plane
icon: https://guide.opencord.org/logos/cord.svg
-version: 0.1.18
+version: 0.1.19
diff --git a/omec/omec-control-plane/templates/service-mme.yaml b/omec/omec-control-plane/templates/service-mme.yaml
index 7012f84..0e52bac 100644
--- a/omec/omec-control-plane/templates/service-mme.yaml
+++ b/omec/omec-control-plane/templates/service-mme.yaml
@@ -38,6 +38,11 @@
- name: s1ap
port: {{ index $configJsonS1ap "sctp_port" }}
protocol: SCTP
+{{- if .Values.prometheusExporter.mme.enabled }}
+ - name: exporter
+ port: 3081
+ protocol: TCP
+{{- end }}
---
apiVersion: v1
kind: Service
@@ -87,3 +92,9 @@
port: {{ index $configJsonS1ap "sctp_port" }}
nodePort: {{ index $configJsonS1ap "sctp_port_external" }}
protocol: SCTP
+ {{- if .Values.prometheusExporter.mme.enabled }}
+ - name: exporter
+ port: 3081
+ nodePort: {{ .Values.prometheusExporter.mme.port }}
+ protocol: TCP
+ {{- end }}
diff --git a/omec/omec-control-plane/templates/statefulset-mme.yaml b/omec/omec-control-plane/templates/statefulset-mme.yaml
index 2ea0afe..40e3d57 100644
--- a/omec/omec-control-plane/templates/statefulset-mme.yaml
+++ b/omec/omec-control-plane/templates/statefulset-mme.yaml
@@ -214,6 +214,23 @@
- name: coredump
mountPath: /tmp/coredump
{{- end }}
+ {{- if .Values.prometheusExporter.mme.enabled }}
+ - name: subscriber-exporter
+ image: {{ .Values.images.tags.mmeExporter }}
+ imagePullPolicy: {{ .Values.images.pullPolicy }}
+ securityContext:
+ privileged: true
+ command: ["bash", "-xc"]
+ args:
+ - until [ -e /tmp/unix_socket ]; do sleep 1; done; chmod 777 /tmp/unix_socket; while true; do python3 monitor_client.py; sleep 1; done
+ {{- if .Values.resources.enabled }}
+ resources:
+{{ toYaml .Values.resources.mme | indent 10 }}
+ {{- end }}
+ volumeMounts:
+ - name: shared-app
+ mountPath: /tmp
+ {{- end }}
volumes:
- name: scripts
configMap:
diff --git a/omec/omec-control-plane/values.yaml b/omec/omec-control-plane/values.yaml
index a607e98..09bfdee 100644
--- a/omec/omec-control-plane/values.yaml
+++ b/omec/omec-control-plane/values.yaml
@@ -19,6 +19,7 @@
hssdb: docker.io/omecproject/c3po-hssdb:1.0.0
hss: docker.io/omecproject/c3po-hss:1.0.0
mme: docker.io/omecproject/openmme:1.0.0
+ mmeExporter: docker.io/omecproject/mme-exporter:0.1.0
spgwc: docker.io/omecproject/ngic-cp:1.1.0
depCheck: quay.io/stackanetes/kubernetes-entrypoint:v0.3.1
pullPolicy: IfNotPresent
@@ -312,3 +313,8 @@
LOCAL_HIGH_LIMIT_PORT = 65535
REMOTE_LOW_LIMIT_PORT = 0
REMOTE_HIGH_LIMIT_PORT = 65535
+
+prometheusExporter:
+ mme:
+ enabled: true # if it is set to false, subscriber-monitoring will not be operational
+ port: 33081 # for NodePort