Skip to content

Commit 2c57948

Browse files
committed
Don't allow dhclient update resolv.conf
Signed-off-by: rabi <[email protected]>
1 parent 7b0f90a commit 2c57948

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

roles/edpm_bootstrap/tasks/bootstrap.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,15 @@
9898
name: NetworkManager
9999
state: reloaded
100100

101+
- name: Stop dhclient from updating resolv.conf
102+
become: true
103+
ansible.builtin.copy:
104+
dest: /etc/dhcp/dhclient-enter-hooks
105+
mode: "0755"
106+
content: |
107+
#!/bin/sh
108+
make_resolv_conf() { : ; }
109+
101110
- name: Configure swap
102111
ansible.builtin.import_tasks: swap.yml
103112

0 commit comments

Comments
 (0)