diff --git a/plays/lib/volumes.yml b/plays/lib/volumes.yml new file mode 100644 index 0000000..ee00483 --- /dev/null +++ b/plays/lib/volumes.yml @@ -0,0 +1,6 @@ +--- +- name: Attach volume mounts + dokku_storage: + app: "{{ app }}" + mounts: "{{ item }}" + with_items: "{{ lookup('vars', 'mounts', default=[]) }}" diff --git a/plays/pre_deploy.yml b/plays/pre_deploy.yml index 2bb4a54..176f08c 100644 --- a/plays/pre_deploy.yml +++ b/plays/pre_deploy.yml @@ -22,5 +22,8 @@ with_items: "{{ db }}" when: db is defined + - name: Include volume tasks + include: ./lib/volumes.yml + - name: Include env tasks include: ./lib/env.yml