summaryrefslogtreecommitdiffstats
path: root/ansible/roles/nfs/templates/exports.j2
diff options
context:
space:
mode:
Diffstat (limited to 'ansible/roles/nfs/templates/exports.j2')
-rw-r--r--ansible/roles/nfs/templates/exports.j24
1 files changed, 2 insertions, 2 deletions
diff --git a/ansible/roles/nfs/templates/exports.j2 b/ansible/roles/nfs/templates/exports.j2
index 1f6956c2..465c9d21 100644
--- a/ansible/roles/nfs/templates/exports.j2
+++ b/ansible/roles/nfs/templates/exports.j2
@@ -1,3 +1,3 @@
-{% for host in groups.kubernetes[1:] -%}
- {{ nfs_mount_path }} {{ hostvars[host].ansible_host }}(rw,sync,no_root_squash,no_subtree_check)
+{% for host in groups.kubernetes | difference(groups['nfs-server']) -%}
+ {{ nfs_mount_path }} {{ hostvars[host].ansible_host | default(hostvars[host].inventory_hostname) }}(rw,sync,no_root_squash,no_subtree_check)
{% endfor %}