From 4a4f9348b82dfd7611d0219def4235f97ac0f177 Mon Sep 17 00:00:00 2001 From: dongjiang1989 Date: Mon, 4 Mar 2024 12:24:48 +0800 Subject: [PATCH] allow configuration of ipFamilyPolicy Signed-off-by: dongjiang1989 --- charts/alertmanager/Chart.yaml | 2 +- charts/alertmanager/templates/services.yaml | 4 ++++ charts/alertmanager/values.yaml | 6 ++++++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/charts/alertmanager/Chart.yaml b/charts/alertmanager/Chart.yaml index 907c757db231..28c7fa6ac49f 100644 --- a/charts/alertmanager/Chart.yaml +++ b/charts/alertmanager/Chart.yaml @@ -6,7 +6,7 @@ icon: https://raw.githubusercontent.com/prometheus/prometheus.github.io/master/a sources: - https://github.com/prometheus/alertmanager type: application -version: 1.9.0 +version: 1.10.0 appVersion: v0.27.0 kubeVersion: ">=1.19.0-0" keywords: diff --git a/charts/alertmanager/templates/services.yaml b/charts/alertmanager/templates/services.yaml index 9637ae7586de..eefb9ce1615f 100644 --- a/charts/alertmanager/templates/services.yaml +++ b/charts/alertmanager/templates/services.yaml @@ -13,6 +13,10 @@ metadata: {{- end }} namespace: {{ include "alertmanager.namespace" . }} spec: + {{- if .Values.service.ipDualStack.enabled }} + ipFamilies: {{ toYaml .Values.service.ipDualStack.ipFamilies | nindent 4 }} + ipFamilyPolicy: {{ .Values.service.ipDualStack.ipFamilyPolicy }} + {{- end }} type: {{ .Values.service.type }} {{- with .Values.service.loadBalancerIP }} loadBalancerIP: {{ . }} diff --git a/charts/alertmanager/values.yaml b/charts/alertmanager/values.yaml index 532ab9f6086d..3bf947a32b5d 100644 --- a/charts/alertmanager/values.yaml +++ b/charts/alertmanager/values.yaml @@ -114,6 +114,12 @@ service: # Optionally specify extra list of additional ports exposed on both services extraPorts: [] + # ip dual stack + ipDualStack: + enabled: false + ipFamilies: ["IPv6", "IPv4"] + ipFamilyPolicy: "PreferDualStack" + # Configuration for creating a separate Service for each statefulset Alertmanager replica # servicePerReplica: