Skip to content

Commit c8bb426

Browse files
committed
Symlink /nfs to /storage/replicated/nfs
We need to use `force: true` because NFS may not be mounted yet (so target is missing) and use `follow: false` to avoid Ansible trying to change ownership of the target.
1 parent d3d0ecc commit c8bb426

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

environments/site/hooks/pre.yml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,17 @@
1212
group: root
1313
owner: root
1414
state: link
15-
force: yes
15+
16+
- name: Ensure /nfs symlink exists
17+
hosts: cluster
18+
become: true
19+
tasks:
20+
# Symlink /nfs to /storage/replicated/nfs
21+
- ansible.builtin.file:
22+
dest: /nfs
23+
src: /storage/replicated/nfs
24+
follow: false
25+
force: true
26+
group: root
27+
owner: root
28+
state: link

0 commit comments

Comments
 (0)