From 8dc188a81e64905e92cbbc2f9af65a9357e7ab57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micka=C3=ABl=20Can=C3=A9vet?= Date: Tue, 10 Mar 2020 15:05:36 +0100 Subject: [PATCH] Allow to override AlertManager's target port (#21251) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mickaël Canévet --- stable/prometheus-operator/Chart.yaml | 2 +- stable/prometheus-operator/README.md | 1 + stable/prometheus-operator/templates/alertmanager/service.yaml | 2 +- stable/prometheus-operator/values.yaml | 3 +++ 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/stable/prometheus-operator/Chart.yaml b/stable/prometheus-operator/Chart.yaml index 14f70fda7782..011602b7cb66 100644 --- a/stable/prometheus-operator/Chart.yaml +++ b/stable/prometheus-operator/Chart.yaml @@ -12,7 +12,7 @@ sources: - https://github.com/coreos/kube-prometheus - https://github.com/coreos/prometheus-operator - https://coreos.com/operators/prometheus -version: 8.11.2 +version: 8.12.0 appVersion: 0.37.0 tillerVersion: ">=2.12.0" home: https://github.com/coreos/prometheus-operator diff --git a/stable/prometheus-operator/README.md b/stable/prometheus-operator/README.md index 4d7667bf2818..eb596ee0368e 100644 --- a/stable/prometheus-operator/README.md +++ b/stable/prometheus-operator/README.md @@ -398,6 +398,7 @@ The following tables list the configurable parameters of the prometheus-operator | `alertmanager.service.loadBalancerSourceRanges` | Alertmanager Load Balancer Source Ranges | `[]` | | `alertmanager.service.nodePort` | Alertmanager Service port for NodePort service type | `30903` | | `alertmanager.service.port` | Port for Alertmanager Service to listen on | `9093` | +| `alertmanager.service.targetPort` | AlertManager Service internal port | `9093` | | `alertmanager.service.type` | Alertmanager Service type | `ClusterIP` | | `alertmanager.serviceAccount.create` | Create a `serviceAccount` for alertmanager | `true` | | `alertmanager.serviceAccount.name` | Name for Alertmanager service account | `""` | diff --git a/stable/prometheus-operator/templates/alertmanager/service.yaml b/stable/prometheus-operator/templates/alertmanager/service.yaml index f1da682b23a1..8647e9ea695d 100644 --- a/stable/prometheus-operator/templates/alertmanager/service.yaml +++ b/stable/prometheus-operator/templates/alertmanager/service.yaml @@ -37,7 +37,7 @@ spec: nodePort: {{ .Values.alertmanager.service.nodePort }} {{- end }} port: {{ .Values.alertmanager.service.port }} - targetPort: 9093 + targetPort: {{ .Values.alertmanager.service.targetPort }} protocol: TCP selector: app: alertmanager diff --git a/stable/prometheus-operator/values.yaml b/stable/prometheus-operator/values.yaml index 62a24680c070..cca45b78f9cc 100644 --- a/stable/prometheus-operator/values.yaml +++ b/stable/prometheus-operator/values.yaml @@ -199,6 +199,9 @@ alertmanager: ## Port for Alertmanager Service to listen on ## port: 9093 + ## To be used with a proxy extraContainer port + ## + targetPort: 9093 ## Port to expose on each node ## Only used if service.type is 'NodePort' ##