From 48d9eaf777235cedc0c8f4a469cd7f0d81bf86ef Mon Sep 17 00:00:00 2001 From: Marius Alwan Meyer <22202402+Sporqist@users.noreply.github.com> Date: Sun, 6 Mar 2022 21:00:36 +0100 Subject: [PATCH 1/3] fixed prometheusScraping.port --- rocketchat/templates/chat-deployment.yaml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/rocketchat/templates/chat-deployment.yaml b/rocketchat/templates/chat-deployment.yaml index 07bd181..cc0db8e 100644 --- a/rocketchat/templates/chat-deployment.yaml +++ b/rocketchat/templates/chat-deployment.yaml @@ -150,8 +150,10 @@ spec: ports: - name: http containerPort: 3000 + {{- if .Values.prometheusScraping.enabled }} - name: metrics - containerPort: 9458 + containerPort: "{{ .Values.prometheusScraping.port }}" + {{- end}} {{- if .Values.livenessProbe.enabled }} livenessProbe: httpGet: @@ -214,4 +216,4 @@ spec: app.kubernetes.io/name: {{ include "rocketchat.name" . }} app.kubernetes.io/instance: {{ .Release.Name }} {{- end }} -{{- end }} \ No newline at end of file +{{- end }} From a1c82af074375222b3a952bb848e57eafe4d0223 Mon Sep 17 00:00:00 2001 From: Marius Meyer <22202402+Sporqist@users.noreply.github.com> Date: Mon, 7 Mar 2022 01:23:22 +0100 Subject: [PATCH 2/3] formatting --- rocketchat/templates/chat-deployment.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rocketchat/templates/chat-deployment.yaml b/rocketchat/templates/chat-deployment.yaml index cc0db8e..1f5bbc8 100644 --- a/rocketchat/templates/chat-deployment.yaml +++ b/rocketchat/templates/chat-deployment.yaml @@ -152,7 +152,7 @@ spec: containerPort: 3000 {{- if .Values.prometheusScraping.enabled }} - name: metrics - containerPort: "{{ .Values.prometheusScraping.port }}" + containerPort: {{ .Values.prometheusScraping.port }} {{- end}} {{- if .Values.livenessProbe.enabled }} livenessProbe: From 273a1b324a08b91b042246724e7228d3f9004cc4 Mon Sep 17 00:00:00 2001 From: Marius Alwan Meyer <22202402+Sporqist@users.noreply.github.com> Date: Mon, 7 Mar 2022 01:19:32 +0100 Subject: [PATCH 3/3] added metrics port to service --- rocketchat/templates/service.yaml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/rocketchat/templates/service.yaml b/rocketchat/templates/service.yaml index 50b69f4..3ef9ca8 100644 --- a/rocketchat/templates/service.yaml +++ b/rocketchat/templates/service.yaml @@ -30,6 +30,12 @@ spec: nodePort: {{ $service.nodePort }} {{- end }} protocol: TCP + {{- if .Values.prometheusScraping.enabled }} + - name: metrics + port: {{ .Values.prometheusScraping.port }} + targetPort: metrics + protocol: TCP + {{- end }} selector: app.kubernetes.io/name: {{ include "rocketchat.name" . }} - app.kubernetes.io/instance: {{ .Release.Name }} \ No newline at end of file + app.kubernetes.io/instance: {{ .Release.Name }}