diff --git a/roles/home-permanent/tasks/main.yml b/roles/home-permanent/tasks/main.yml index 41e03224650c34124a18d8a4fb5f5119ebff77d6..eb1c537b880f8b3c63e97e81452233bb898f911a 100644 --- a/roles/home-permanent/tasks/main.yml +++ b/roles/home-permanent/tasks/main.yml @@ -5,9 +5,16 @@ dest: /etc/systemd/system/home.mount mode: 0755 -- name: Load and activate nfs systemd mount +- name: Load and activate nfs home systemd mount systemd: name: home.mount daemon_reload: true enabled: true state: started + +- name: Load and activate nfs mail systemd mount + systemd: + name: var-mail.mount + daemon_reload: true + enabled: true + state: started diff --git a/roles/home-permanent/templates/systemd/system/home.mount.j2 b/roles/home-permanent/templates/systemd/system/home.mount.j2 index f5450959cb6f98453615db1bfaa5240bbf35d85d..7a64956e14c26591d018484e5396bcb6c9c0aaee 100644 --- a/roles/home-permanent/templates/systemd/system/home.mount.j2 +++ b/roles/home-permanent/templates/systemd/system/home.mount.j2 @@ -1,11 +1,11 @@ {{ ansible_header | comment }} [Unit] -Description=Mount home-adh on zbee +Description=Mount pool/home on cameron Wants=network-online.target After=network-online.target [Mount] -What=nfs.adm.crans.org:/home-adh +What=cameron.adm.crans.org:/pool/home Where=/home Type=nfs Options=rw,nosuid diff --git a/roles/home-permanent/templates/systemd/system/var-mail.mount.j2 b/roles/home-permanent/templates/systemd/system/var-mail.mount.j2 new file mode 100644 index 0000000000000000000000000000000000000000..2466e2a25fa537b99fca295f71dd7ba536e4ea85 --- /dev/null +++ b/roles/home-permanent/templates/systemd/system/var-mail.mount.j2 @@ -0,0 +1,14 @@ +{{ ansible_header | comment }} +[Unit] +Description=Mount pool/mail on cameron +Wants=network-online.target +After=network-online.target + +[Mount] +What=cameron.adm.crans.org:/pool/mail +Where=/var/mail +Type=nfs +Options=rw,nosuid + +[Install] +WantedBy=multi-user.target