diff --git a/plays/lib/volumes.yml b/plays/lib/volumes.yml index ee00483..1a71dd7 100644 --- a/plays/lib/volumes.yml +++ b/plays/lib/volumes.yml @@ -1,6 +1,17 @@ --- +- name: Create volume mount directories + become: true + file: + path: "{{ item }}" + state: directory + owner: dokku + group: dokku + with_items: "{{ mounts }}" + when: mounts is defined + - name: Attach volume mounts dokku_storage: app: "{{ app }}" mounts: "{{ item }}" - with_items: "{{ lookup('vars', 'mounts', default=[]) }}" + with_items: "{{ mounts }}" + when: mounts is defined