Skip to content

Commit 69ab2cd

Browse files
committed
Do not change the owner, group, or mode of the target when creating the symlink
1 parent 2c76623 commit 69ab2cd

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

tasks/main.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,11 @@
2121

2222
- name: Create /etc/resolv.conf symlink
2323
ansible.builtin.file:
24+
# Do not apply any group, owner, or mode changes to src.
25+
follow: false
2426
# If a file is already present at /etc/resolv.conf then just
2527
# delete it.
2628
force: true
27-
group: root
28-
mode: u=rw,g=r,o=r
29-
owner: root
3029
path: /etc/resolv.conf
3130
src: /run/systemd/resolve/stub-resolv.conf
3231
state: link

0 commit comments

Comments
 (0)