Skip to content
This repository has been archived by the owner on Oct 10, 2023. It is now read-only.

ignore dns servers from dhcp when providing nameservers #4023

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
Original file line number Diff line number Diff line change
Expand Up @@ -1087,8 +1087,20 @@ spec:
- {{ . }}
{{- end }}
{{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp4: true {{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp6: true {{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp4: true
{{ if .controlPlane.network.nameservers -}}
dhcp4Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp6: true
{{ if .controlPlane.network.nameservers -}}
dhcp6Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if .network.addressesFromPools -}}
addressesFromPools:
{{- range .network.addressesFromPools }}
Expand Down Expand Up @@ -1124,8 +1136,20 @@ spec:
- {{ . }}
{{- end }}
{{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp4: true {{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp6: true {{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp4: true
{{ if .worker.network.nameservers -}}
dhcp4Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp6: true
{{ if .worker.network.nameservers -}}
dhcp6Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if .network.addressesFromPools -}}
addressesFromPools:
{{- range .network.addressesFromPools }}
Expand Down
32 changes: 28 additions & 4 deletions providers/infrastructure-vsphere/v1.5.1/cconly/base.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1087,8 +1087,20 @@ spec:
- {{ . }}
{{- end }}
{{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp4: true {{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp6: true {{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp4: true
{{ if .controlPlane.network.nameservers -}}
dhcp4Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp6: true
{{ if .controlPlane.network.nameservers -}}
dhcp6Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if .network.addressesFromPools -}}
addressesFromPools:
{{- range .network.addressesFromPools }}
Expand Down Expand Up @@ -1124,8 +1136,20 @@ spec:
- {{ . }}
{{- end }}
{{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp4: true {{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}} dhcp6: true {{- end }}
{{ if list "IPv4" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp4: true
{{ if .worker.network.nameservers -}}
dhcp4Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if list "IPv6" "DualStack" | has .builtin.cluster.network.ipFamily | and (empty .network.addressesFromPools) -}}
dhcp6: true
{{ if .worker.network.nameservers -}}
dhcp6Overrides:
useDNS: false
{{- end }}
{{- end }}
{{ if .network.addressesFromPools -}}
addressesFromPools:
{{- range .network.addressesFromPools }}
Expand Down