From 88d193547e8ce68e21ad6dd962275b8aaa92213d Mon Sep 17 00:00:00 2001 From: Denis Shatokhin Date: Thu, 14 Aug 2025 17:29:49 +0300 Subject: [PATCH 1/5] chore(scripts): fix `helm schema` flag Signed-off-by: Denis Shatokhin --- scripts/helm-tools.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/helm-tools.sh b/scripts/helm-tools.sh index 825a22c84a..2ea42c468b 100755 --- a/scripts/helm-tools.sh +++ b/scripts/helm-tools.sh @@ -67,8 +67,8 @@ update_schema() { diff_schema() { cd charts/external-dns - helm schema \ - -output diff-schema.schema.json + helm schema \ + --output diff-schema.schema.json trap 'rm -rf -- "diff-schema.schema.json"' EXIT CURRENT_SCHEMA=$(cat values.schema.json) GENERATED_SCHEMA=$(cat diff-schema.schema.json) From 7fce7a0f816350d60e32e61d401d3f4838371616 Mon Sep 17 00:00:00 2001 From: Denis Shatokhin Date: Thu, 14 Aug 2025 17:32:41 +0300 Subject: [PATCH 2/5] feat(chart): add option to configure `annotationFilter` via dedicated helm value Signed-off-by: Denis Shatokhin --- charts/external-dns/README.md | 1 + charts/external-dns/templates/deployment.yaml | 3 ++ charts/external-dns/values.schema.json | 33 ++++++++++++------- charts/external-dns/values.yaml | 15 +++++---- 4 files changed, 34 insertions(+), 18 deletions(-) diff --git a/charts/external-dns/README.md b/charts/external-dns/README.md index 33286d9141..2767b47f14 100644 --- a/charts/external-dns/README.md +++ b/charts/external-dns/README.md @@ -94,6 +94,7 @@ If `namespaced` is set to `true`, please ensure that `sources` my only contains | Key | Type | Default | Description | |-----|------|---------|-------------| | affinity | object | `{}` | Affinity settings for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/). If an explicit label selector is not provided for pod affinity or pod anti-affinity one will be created from the pod selector labels. | +| annotationFilter | string | `nil` | Filter resources queried for endpoints by annotation selector | | automountServiceAccountToken | bool | `true` | Set this to `false` to [opt out of API credential automounting](https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/#opt-out-of-api-credential-automounting) for the `Pod`. | | commonLabels | object | `{}` | Labels to add to all chart resources. | | deploymentAnnotations | object | `{}` | Annotations to add to the `Deployment`. | diff --git a/charts/external-dns/templates/deployment.yaml b/charts/external-dns/templates/deployment.yaml index 7db118370b..70f231fb4a 100644 --- a/charts/external-dns/templates/deployment.yaml +++ b/charts/external-dns/templates/deployment.yaml @@ -123,6 +123,9 @@ spec: {{- if .Values.labelFilter }} - --label-filter={{ .Values.labelFilter }} {{- end }} + {{- if .Values.annotationFilter }} + - --annotation-filter={{ .Values.annotationFilter }} + {{- end }} {{- range .Values.managedRecordTypes }} - --managed-record-types={{ . }} {{- end }} diff --git a/charts/external-dns/values.schema.json b/charts/external-dns/values.schema.json index 75e7fdd42f..9b25252f3e 100644 --- a/charts/external-dns/values.schema.json +++ b/charts/external-dns/values.schema.json @@ -6,6 +6,13 @@ "description": "Affinity settings for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/). If an explicit label selector is not provided for pod affinity or pod anti-affinity one will be created from the pod selector labels.", "type": "object" }, + "annotationFilter": { + "description": "Filter resources queried for endpoints by annotation selector", + "type": [ + "string", + "null" + ] + }, "automountServiceAccountToken": { "description": "Set this to `false` to [opt out of API credential automounting](https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/#opt-out-of-api-credential-automounting) for the `Pod`.", "type": "boolean" @@ -23,9 +30,8 @@ "type": "object", "properties": { "type": { - "type": [ - "string" - ], + "default": "Recreate", + "type": "string", "enum": [ "Recreate", "RollingUpdate" @@ -98,6 +104,13 @@ "null" ] }, + "gatewayNamespace": { + "description": "_Gateway API_ gateway namespace to watch.", + "type": [ + "string", + "null" + ] + }, "global": { "type": "object", "properties": { @@ -192,9 +205,7 @@ "logFormat": { "description": "Log format.", "default": "text", - "type": [ - "string" - ], + "type": "string", "enum": [ "text", "json" @@ -203,9 +214,7 @@ "logLevel": { "description": "Log level.", "default": "info", - "type": [ - "string" - ], + "type": "string", "enum": [ "panic", "debug", @@ -272,9 +281,7 @@ "policy": { "description": "How DNS records are synchronized between sources and providers; available values are `create-only`, `sync`, \u0026 `upsert-only`.", "default": "upsert-only", - "type": [ - "string" - ], + "type": "string", "enum": [ "create-only", "sync", @@ -367,6 +374,7 @@ ] }, "port": { + "default": "string", "type": [ "integer", "string" @@ -420,6 +428,7 @@ ] }, "port": { + "default": "string", "type": [ "integer", "string" diff --git a/charts/external-dns/values.yaml b/charts/external-dns/values.yaml index dc5ec8d1eb..6ba9bafcb4 100644 --- a/charts/external-dns/values.yaml +++ b/charts/external-dns/values.yaml @@ -12,7 +12,7 @@ image: # @schema additionalProperties: false # -- Image tag for the `external-dns` container, this will default to `.Chart.AppVersion` if not set. tag: # @schema type:[string, null] # -- Image pull policy for the `external-dns` container. - pullPolicy: IfNotPresent # @schema enum:[IfNotPresent, Always]; + pullPolicy: IfNotPresent # @schema enum:[IfNotPresent, Always] # -- Image pull secrets. imagePullSecrets: [] # @schema item: object @@ -44,11 +44,11 @@ service: # -- Service HTTP port. port: 7979 # @schema minimum:0; default:7979 # -- Service IP families (e.g. IPv4 and/or IPv6). - ipFamilies: [] # @schema type: [array, null]; item: string; itemEnum: ["IPv4", "IPv6"]; minItems:0; maxItems:2; uniqueItems: true; + ipFamilies: [] # @schema type: [array, null]; item: string; itemEnum: ["IPv4", "IPv6"]; minItems:0; maxItems:2; uniqueItems: true # - IPv4 # - IPv6 # -- Service IP family policy. - ipFamilyPolicy: # @schema type: [string, null]; enum:[SingleStack, PreferDualStack, RequireDualStack, null]; + ipFamilyPolicy: # @schema type: [string, null]; enum:[SingleStack, PreferDualStack, RequireDualStack, null] rbac: # @schema additionalProperties: true # -- If `true`, create a `ClusterRole` & `ClusterRoleBinding` with access to the Kubernetes API. @@ -237,10 +237,13 @@ excludeDomains: [] # -- Filter resources queried for endpoints by label selector labelFilter: # @schema type: [string,null]; default: null +# -- Filter resources queried for endpoints by annotation selector +annotationFilter: # @schema type: [string,null]; default: null + # -- Record types to manage (default: A, AAAA, CNAME) -managedRecordTypes: [] # @schema type: [array, null]; item: string; uniqueItems: true; +managedRecordTypes: [] # @schema type: [array, null]; item: string; uniqueItems: true -provider: # @schema type: [object, string]; +provider: # @schema type: [object, string] # -- _ExternalDNS_ provider name; for the available providers and how to configure them see [README](https://github.com/kubernetes-sigs/external-dns/blob/master/charts/external-dns/README.md#providers). name: aws webhook: @@ -300,7 +303,7 @@ provider: # @schema type: [object, string]; # -- Extra arguments to provide to _ExternalDNS_. # An array or map can be used, with maps allowing for value overrides; maps also support slice values to use the same arg multiple times. -extraArgs: {} # @schema type: [array, null, object]; item: string; uniqueItems: true; +extraArgs: {} # @schema type: [array, null, object]; item: string; uniqueItems: true secretConfiguration: # -- If `true`, create a `Secret` to store sensitive provider configuration (**DEPRECATED**). From 1232a130789a981546fea5043071f8fa6fbced7e Mon Sep 17 00:00:00 2001 From: Denis Shatokhin Date: Thu, 14 Aug 2025 17:37:20 +0300 Subject: [PATCH 3/5] chore(docs): update changelog with pr Signed-off-by: Denis Shatokhin --- charts/external-dns/CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/charts/external-dns/CHANGELOG.md b/charts/external-dns/CHANGELOG.md index b0e88965d5..3691f91539 100644 --- a/charts/external-dns/CHANGELOG.md +++ b/charts/external-dns/CHANGELOG.md @@ -18,6 +18,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [UNRELEASED] +- Added option to configure `annotationFilter` via dedicated helm value. ([#5737](https://github.com/kubernetes-sigs/external-dns/pull/5737)) _@dshatokhin_ + ## [v1.18.0] - 2025-07-14 ### Changed From 060d41843584a17498e8ec0b343fa73995127dff Mon Sep 17 00:00:00 2001 From: Denis Shatokhin Date: Thu, 14 Aug 2025 19:58:21 +0300 Subject: [PATCH 4/5] chore(chart): add period to the description string Signed-off-by: Denis Shatokhin --- charts/external-dns/README.md | 4 ++-- charts/external-dns/values.schema.json | 4 ++-- charts/external-dns/values.yaml | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/charts/external-dns/README.md b/charts/external-dns/README.md index 2767b47f14..bae1d5f238 100644 --- a/charts/external-dns/README.md +++ b/charts/external-dns/README.md @@ -94,7 +94,7 @@ If `namespaced` is set to `true`, please ensure that `sources` my only contains | Key | Type | Default | Description | |-----|------|---------|-------------| | affinity | object | `{}` | Affinity settings for `Pod` [scheduling](https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/). If an explicit label selector is not provided for pod affinity or pod anti-affinity one will be created from the pod selector labels. | -| annotationFilter | string | `nil` | Filter resources queried for endpoints by annotation selector | +| annotationFilter | string | `nil` | Filter resources queried for endpoints by annotation selector. | | automountServiceAccountToken | bool | `true` | Set this to `false` to [opt out of API credential automounting](https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/#opt-out-of-api-credential-automounting) for the `Pod`. | | commonLabels | object | `{}` | Labels to add to all chart resources. | | deploymentAnnotations | object | `{}` | Annotations to add to the `Deployment`. | @@ -118,7 +118,7 @@ If `namespaced` is set to `true`, please ensure that `sources` my only contains | imagePullSecrets | list | `[]` | Image pull secrets. | | initContainers | list | `[]` | [Init containers](https://kubernetes.io/docs/concepts/workloads/pods/init-containers/) to add to the `Pod` definition. | | interval | string | `"1m"` | Interval for DNS updates. | -| labelFilter | string | `nil` | Filter resources queried for endpoints by label selector | +| labelFilter | string | `nil` | Filter resources queried for endpoints by label selector. | | livenessProbe | object | See _values.yaml_ | [Liveness probe](https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/) configuration for the `external-dns` container. | | logFormat | string | `"text"` | Log format. | | logLevel | string | `"info"` | Log level. | diff --git a/charts/external-dns/values.schema.json b/charts/external-dns/values.schema.json index 9b25252f3e..22bfef2ab5 100644 --- a/charts/external-dns/values.schema.json +++ b/charts/external-dns/values.schema.json @@ -7,7 +7,7 @@ "type": "object" }, "annotationFilter": { - "description": "Filter resources queried for endpoints by annotation selector", + "description": "Filter resources queried for endpoints by annotation selector.", "type": [ "string", "null" @@ -164,7 +164,7 @@ "type": "string" }, "labelFilter": { - "description": "Filter resources queried for endpoints by label selector", + "description": "Filter resources queried for endpoints by label selector.", "type": [ "string", "null" diff --git a/charts/external-dns/values.yaml b/charts/external-dns/values.yaml index 6ba9bafcb4..9b9292c512 100644 --- a/charts/external-dns/values.yaml +++ b/charts/external-dns/values.yaml @@ -234,10 +234,10 @@ domainFilters: [] # -- Intentionally exclude domains from being managed. excludeDomains: [] -# -- Filter resources queried for endpoints by label selector +# -- Filter resources queried for endpoints by label selector. labelFilter: # @schema type: [string,null]; default: null -# -- Filter resources queried for endpoints by annotation selector +# -- Filter resources queried for endpoints by annotation selector. annotationFilter: # @schema type: [string,null]; default: null # -- Record types to manage (default: A, AAAA, CNAME) From 31a181efaa7a19780f1ea7362dd797b6da5d876a Mon Sep 17 00:00:00 2001 From: Denis Shatokhin Date: Thu, 14 Aug 2025 19:58:54 +0300 Subject: [PATCH 5/5] chore(docs): update changelog list of changes Signed-off-by: Denis Shatokhin --- charts/external-dns/CHANGELOG.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/charts/external-dns/CHANGELOG.md b/charts/external-dns/CHANGELOG.md index 3691f91539..ad2643b86d 100644 --- a/charts/external-dns/CHANGELOG.md +++ b/charts/external-dns/CHANGELOG.md @@ -18,7 +18,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [UNRELEASED] -- Added option to configure `annotationFilter` via dedicated helm value. ([#5737](https://github.com/kubernetes-sigs/external-dns/pull/5737)) _@dshatokhin_ +### Added + +- Add option to configure `annotationFilter` via dedicated chart value. ([#5737](https://github.com/kubernetes-sigs/external-dns/pull/5737)) _@dshatokhin_ ## [v1.18.0] - 2025-07-14