prole/infrastructure/roles/iscsi/tasks/iscsi_mount.yml

15 lines
345 B
YAML

---
- name: Ensure mountpoint exists
ansible.builtin.file:
path: "{{ m.path }}"
state: directory
mode: "0755"
- name: Mount {{ m.path }}
ansible.builtin.mount:
path: "{{ m.path }}"
src: "{{ m.src }}"
fstype: "{{ m.fstype | default('ext4') }}"
opts: "{{ m.opts | default('_netdev,noatime') }}"
state: mounted