28 lines
720 B
YAML
28 lines
720 B
YAML
|
- name: "(Re)Create {{ project_dir }} project directory"
|
||
|
file:
|
||
|
path: "{{ project_dir }}"
|
||
|
state: "{{ item }}"
|
||
|
loop:
|
||
|
- absent
|
||
|
- directory
|
||
|
|
||
|
- name: Template docker-compose.yaml & .env to project directory
|
||
|
template:
|
||
|
src: "{{ item }}"
|
||
|
dest: "{{ project_dir }}/{{ item }}"
|
||
|
owner: "{{ host_uid }}"
|
||
|
group: "{{ host_uid }}"
|
||
|
mode: '600'
|
||
|
loop:
|
||
|
- docker-compose.yaml
|
||
|
- .env
|
||
|
|
||
|
- name: "Create (if not exists) directory {{ volumes['hedgedoc_uploadsdir'] }} & set permissions"
|
||
|
file:
|
||
|
path: "{{ volumes['hedgedoc_uploadsdir'] }}"
|
||
|
state: directory
|
||
|
owner: "{{ users['hedgedoc'] + uid_shift }}"
|
||
|
group: "{{ users['hedgedoc'] + uid_shift }}"
|
||
|
mode: '700'
|
||
|
become: true
|