xoxys.freshrss_docker/tasks/setup.yml
Robert Kaussow 31924d6a29
All checks were successful
continuous-integration/drone/pr Build is passing
remove systemd and use native docker-compose
2020-06-17 22:32:10 +02:00

29 lines
849 B
YAML

---
- block:
- name: Ensure service directory exists
file:
path: "{{ freshrss_service_directory }}"
state: directory
mode: 0755
- name: Deploy compose file to '{{ freshrss_service_directory }}'
template:
src: "services/freshrss-compose.yml.j2"
dest: "{{ freshrss_service_directory }}/docker-compose.yml"
owner: root
group: root
mode: 0640
validate: "docker-compose -f %s config -q"
- name: Ensure service is up and running
docker_compose:
project_src: "{{ freshrss_service_directory }}"
pull: yes
remove_orphans: yes
stopped: "{{ freshrss_service_stopped }}"
state: present
# temp. disable changes; breaks idempotency for whatever reason
changed_when: False
become: True
become_user: root