radiator-web/deployment/deployment.yml
Alexander Detsch e24b0f3660 added ci/cd
2021-04-04 15:35:36 +02:00

23 lines
639 B
YAML

---
- hosts: snickers-docker
gather_facts: no
vars:
verbose: false
compose_folder: "/mnt/docker-storage/radiator-web/"
tasks:
- name: Ensures {{ compose_folder }} dir exists
stat:
path: "{{ compose_folder }}docker-compose.yml"
register: file_details
- name: Fail if docker-compose file doesn't exist
fail:
msg: "docker-compose.yml doesn't exist in expected location (expected in {{ compose_folder }})"
when: not file_details.stat.exists
- name: Update container image
community.general.docker_compose:
project_src: "{{ compose_folder }}"
pull: yes