Skip to content

Commit 0ab461d

Browse files
authored
allow for dnsConfig directive (#571)
* allow for dnsConfig directive * 📝 readme
1 parent 33c6238 commit 0ab461d

File tree

5 files changed

+14
-0
lines changed

5 files changed

+14
-0
lines changed

config/helm/aws-node-termination-handler/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,7 @@ The configuration in this table applies to AWS Node Termination Handler in IMDS
133133
| `podMonitor.sampleLimit` | Number of scraped samples accepted. | `5000` |
134134
| `useHostNetwork` | If `true`, enables `hostNetwork` for the Linux DaemonSet. NOTE: setting this to `false` may cause issues accessing IMDSv2 if your account is not configured with an IP hop count of 2 see [Metrics Endpoint Considerations](#metrics-endpoint-considerations) | `true` |
135135
| `dnsPolicy` | If specified, this overrides `linuxDnsPolicy` and `windowsDnsPolicy` with a single policy. | `""` |
136+
| `dnsConfig` | If specified, this sets the dnsConfig: https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#pod-dns-config | `{}` |
136137
| `linuxDnsPolicy` | DNS policy for the Linux DaemonSet. | `""` |
137138
| `windowsDnsPolicy` | DNS policy for the Windows DaemonSet. | `""` |
138139
| `daemonsetNodeSelector` | Expressions to select a node by it's labels for DaemonSet pod assignment. For backwards compatibility the `nodeSelector` value has priority over this but shouldn't be used. | `{}` |

config/helm/aws-node-termination-handler/templates/daemonset.linux.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ spec:
4545
{{- end }}
4646
hostNetwork: {{ .Values.useHostNetwork }}
4747
dnsPolicy: {{ default .Values.linuxDnsPolicy .Values.dnsPolicy }}
48+
{{- if .Values.dnsConfig }}
49+
dnsConfig:
50+
{{- toYaml . | nindent 10 }}
51+
{{- end }}
4852
containers:
4953
- name: aws-node-termination-handler
5054
{{- with .Values.securityContext }}

config/helm/aws-node-termination-handler/templates/daemonset.windows.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ spec:
4545
{{- end }}
4646
hostNetwork: false
4747
dnsPolicy: {{ default .Values.windowsDnsPolicy .Values.dnsPolicy }}
48+
{{- if .Values.dnsConfig }}
49+
dnsConfig:
50+
{{- toYaml . | nindent 10 }}
51+
{{- end }}
4852
containers:
4953
- name: aws-node-termination-handler
5054
{{- with .Values.securityContext }}

config/helm/aws-node-termination-handler/templates/deployment.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,10 @@ spec:
4242
{{- with .Values.terminationGracePeriodSeconds }}
4343
terminationGracePeriodSeconds: {{ . }}
4444
{{- end }}
45+
{{- if .Values.dnsConfig }}
46+
dnsConfig:
47+
{{- toYaml . | nindent 10 }}
48+
{{- end }}
4549
containers:
4650
- name: aws-node-termination-handler
4751
{{- with .Values.securityContext }}

config/helm/aws-node-termination-handler/values.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,7 @@ useHostNetwork: true
219219

220220
# Daemonset DNS policy
221221
dnsPolicy: ""
222+
dnsConfig: {}
222223
linuxDnsPolicy: ClusterFirstWithHostNet
223224
windowsDnsPolicy: ClusterFirst
224225

0 commit comments

Comments
 (0)