homelab/roles/mount-nfs/tasks/main.yml

14 lines
272 B
YAML
Raw Normal View History

2022-11-12 12:21:39 +01:00
---
- name: Install NFS client.
apt:
name: nfs-common
state: present
- name: Mount NFS share.
ansible.posix.mount:
src: {{ hostvars['admin']['ansible_host'] }}:/mnt/data
path: /mnt/data
fstype: nfs4
opts: defaults,user,exec
state: mounted