From 4cbc02a65f7c1bfef4cd4b03e3556a289b2f2014 Mon Sep 17 00:00:00 2001 From: residualmind Date: Wed, 26 Jun 2019 22:37:20 +0200 Subject: [PATCH] [stable/redis-ha] define prometheus exporter port in service (#14910) * define prometheus exporter port in service This enables prometheus-operator to work with this chart almost out-of-the box. Only a ServiceMonitor definition is necessary. Signed-off-by: Ben Dimbeck * bump chart version Signed-off-by: Ben Dimbeck --- stable/redis-ha/Chart.yaml | 2 +- stable/redis-ha/templates/redis-ha-service.yaml | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/stable/redis-ha/Chart.yaml b/stable/redis-ha/Chart.yaml index a9a32ec0cf..039aa42b59 100644 --- a/stable/redis-ha/Chart.yaml +++ b/stable/redis-ha/Chart.yaml @@ -6,7 +6,7 @@ keywords: - redis - keyvalue - database -version: 3.5.0 +version: 3.5.1 appVersion: 5.0.3 description: Highly available Kubernetes implementation of Redis icon: https://upload.wikimedia.org/wikipedia/en/thumb/6/6b/Redis_Logo.svg/1200px-Redis_Logo.svg.png diff --git a/stable/redis-ha/templates/redis-ha-service.yaml b/stable/redis-ha/templates/redis-ha-service.yaml index 388bde8d18..206458ca78 100644 --- a/stable/redis-ha/templates/redis-ha-service.yaml +++ b/stable/redis-ha/templates/redis-ha-service.yaml @@ -20,6 +20,12 @@ spec: port: {{ .Values.sentinel.port }} protocol: TCP targetPort: sentinel +{{- if .Values.exporter.enabled }} + - name: exporter-port + port: {{ .Values.exporter.port }} + protocol: TCP + targetPort: exporter-port +{{- end }} selector: release: {{ .Release.Name }} app: {{ template "redis-ha.name" . }}