diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2023-08-04 12:39:53 +0200 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2023-08-04 12:41:21 +0200 |
commit | ba72e84010822fd3cc2774db9d77ed2f917a1929 (patch) | |
tree | e663a97009a534f583d795fcab2dd90c9a2a0348 /roles/digitalocean_volume/tasks/main.yml | |
parent | import letsencrypt role (diff) | |
download | infra-ansible-ba72e84010822fd3cc2774db9d77ed2f917a1929.tar.gz infra-ansible-ba72e84010822fd3cc2774db9d77ed2f917a1929.zip |
import a couple more roles
Diffstat (limited to 'roles/digitalocean_volume/tasks/main.yml')
-rw-r--r-- | roles/digitalocean_volume/tasks/main.yml | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/roles/digitalocean_volume/tasks/main.yml b/roles/digitalocean_volume/tasks/main.yml new file mode 100644 index 0000000..57ca0e2 --- /dev/null +++ b/roles/digitalocean_volume/tasks/main.yml @@ -0,0 +1,12 @@ +- name: Default mount path + ansible.builtin.set_fact: + volume_dir: "{{ volume_dir | default('/mnt/{{ volume_name }}') }}" + +- name: Mount volume + become: true + ansible.posix.mount: + path: '{{ volume_dir }}' + src: '/dev/disk/by-id/scsi-0DO_Volume_{{ volume_name }}' + state: mounted + fstype: '{{ volume_fs }}' + opts: defaults,nofail,discard |