Skip to content

Commit a456953

Browse files
authored
[release/v1.45] Add missing --resolv-conf to kubelet (#1388)
* Add missing --resolv-conf to kubelet Signed-off-by: Artiom Diomin <[email protected]> * Update fixtures Signed-off-by: Artiom Diomin <[email protected]>
1 parent 048f338 commit a456953

File tree

10 files changed

+32
-4
lines changed

10 files changed

+32
-4
lines changed

pkg/userdata/flatcar/provider.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,10 @@ systemd:
246246
contents: |
247247
[Service]
248248
EnvironmentFile=/etc/kubernetes/nodeip.conf
249+
- name: resolv.conf
250+
contents: |
251+
[Service]
252+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
249253
- name: 40-download.conf
250254
contents: |
251255
[Unit]
@@ -514,6 +518,10 @@ coreos:
514518
content: |
515519
[Service]
516520
EnvironmentFile=/etc/kubernetes/nodeip.conf
521+
- name: resolv.conf
522+
content: |
523+
[Service]
524+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
517525
- name: 40-download.conf
518526
content: |
519527
[Unit]

pkg/userdata/flatcar/testdata/cloud-init_v1.20.14.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ coreos:
8686
content: |
8787
[Service]
8888
EnvironmentFile=/etc/kubernetes/nodeip.conf
89+
- name: resolv.conf
90+
content: |
91+
[Service]
92+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
8993
- name: 40-download.conf
9094
content: |
9195
[Unit]

pkg/userdata/flatcar/testdata/cloud-init_v1.21.8.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ coreos:
8686
content: |
8787
[Service]
8888
EnvironmentFile=/etc/kubernetes/nodeip.conf
89+
- name: resolv.conf
90+
content: |
91+
[Service]
92+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
8993
- name: 40-download.conf
9094
content: |
9195
[Unit]

pkg/userdata/flatcar/testdata/cloud-init_v1.22.5.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ coreos:
8686
content: |
8787
[Service]
8888
EnvironmentFile=/etc/kubernetes/nodeip.conf
89+
- name: resolv.conf
90+
content: |
91+
[Service]
92+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
8993
- name: 40-download.conf
9094
content: |
9195
[Unit]

pkg/userdata/flatcar/testdata/cloud-init_v1.23.0.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ coreos:
8686
content: |
8787
[Service]
8888
EnvironmentFile=/etc/kubernetes/nodeip.conf
89+
- name: resolv.conf
90+
content: |
91+
[Service]
92+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
8993
- name: 40-download.conf
9094
content: |
9195
[Unit]

pkg/userdata/flatcar/testdata/containerd.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,10 @@ coreos:
7171
content: |
7272
[Service]
7373
EnvironmentFile=/etc/kubernetes/nodeip.conf
74+
- name: resolv.conf
75+
content: |
76+
[Service]
77+
Environment="KUBELET_EXTRA_ARGS=--resolv-conf=/run/systemd/resolve/resolv.conf"
7478
- name: 40-download.conf
7579
content: |
7680
[Unit]

pkg/userdata/flatcar/testdata/ignition_v1.20.14.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

pkg/userdata/flatcar/testdata/ignition_v1.21.8.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

pkg/userdata/flatcar/testdata/ignition_v1.22.5.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

pkg/userdata/flatcar/testdata/ignition_v1.23.0.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)