Files
homelab/roles/nfs/tasks/main.yml
Matthew McKinnon 12444311a4
All checks were successful
Deploy / Prepare Build (push) Successful in 13s
Initial Commit
2025-09-08 18:29:40 +10:00

21 lines
429 B
YAML

---
- name: Install NFS mount utility
ansible.builtin.apt:
update_cache: true
pkg: nfs-common
state: present
when: ansible_os_family == "Debian"
- name: Mount an NFS volume
ansible.posix.mount:
src: "{{ item.src }}"
path: "{{ item.path }}"
opts: "{{ item.opts | default(nfs_mount_opts) }}"
state: "{{ item.state | default( 'mounted' ) }}"
fstype: nfs
with_items: "{{ mounts }}"