Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions charts/coredns/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
apiVersion: v2
name: coredns
version: 1.45.1
version: 1.45.2
appVersion: 1.13.1
home: https://coredns.io
icon: https://coredns.io/images/CoreDNS_Colour_Horizontal.png
Expand All @@ -20,8 +20,4 @@ type: application
annotations:
artifacthub.io/changes: |
- kind: added
description: Support for customAnnotations on ClusterRole and ClusterRoleBinding
- kind: added
description: Support for dnsConfig in deployment
- kind: added
description: Support for podLabels
description: Add configurable dnsPolicy for deployment
2 changes: 2 additions & 0 deletions charts/coredns/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,8 @@ The command removes all the Kubernetes components associated with the chart and
| `deployment.name` | Name of the deployment if `deployment.enabled` is true. Otherwise the name of an existing deployment for the autoscaler or HPA to target. | `""` |
| `deployment.annotations` | Annotations to add to the main deployment | `{}` |
| `deployment.selector` | Pod selector | `{}` |
| `deployment.dnsPolicy` | DNS policy for the pod (Default, ClusterFirst, ClusterFirstWithHostNet, None) | `"Default"` |
| `deployment.dnsConfig` | Custom DNS configuration (nameservers, searches, options). Required when dnsPolicy is "None" | `{}` |
| `clusterRole.nameOverride` | ClusterRole name override | |

See `values.yaml` for configuration notes. Specify each parameter using the `--set key=value[,key=value]` argument to `helm install`. For example,
Expand Down
14 changes: 8 additions & 6 deletions charts/coredns/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,15 @@ spec:
{{- if .Values.priorityClassName }}
priorityClassName: {{ .Values.priorityClassName | quote }}
{{- end }}
{{- if .Values.dnsConfig }}
dnsPolicy: None
{{- else if .Values.isClusterService }}
dnsPolicy: Default
{{- if .Values.isClusterService }}
dnsPolicy: {{ .Values.deployment.dnsPolicy }}
{{- end }}
{{- if and (eq .Values.deployment.dnsPolicy "None") (not .Values.deployment.dnsConfig) }}
{{- fail "dnsConfig is required when dnsPolicy is set to None" }}
{{- end }}
{{- if .Values.dnsConfig }}
dnsConfig: {{ toYaml .Values.dnsConfig | nindent 8 }}
{{- with .Values.deployment.dnsConfig }}
dnsConfig:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- if .Values.affinity }}
affinity:
Expand Down
17 changes: 17 additions & 0 deletions charts/coredns/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,23 @@ deployment:
annotations: {}
## Pod selector
selector: {}
# dnsPolicy determines how DNS resolution is handled for the pod.
# When isClusterService is true, this defaults to "Default" to avoid circular DNS resolution.
# Options: Default, ClusterFirst, ClusterFirstWithHostNet, None
# If set to "None", you must provide dnsConfig.
dnsPolicy: "Default"
# dnsConfig allows fine-grained DNS configuration for the pod.
# Only used when dnsPolicy is set to "None" or when custom DNS settings are needed.
# Example:
# dnsConfig:
# nameservers:
# - 8.8.8.8
# searches:
# - my.dns.search.suffix
# options:
# - name: ndots
# value: "2"
dnsConfig: {}

# Configures initcontainers for the coredns deployment.
initContainers: []
Loading