2023-11-17 16:53:56 +01:00
|
|
|
- name: "create {{health_docker_container_folder}}"
|
|
|
|
file:
|
|
|
|
path: "{{health_docker_container_folder}}"
|
|
|
|
state: directory
|
|
|
|
mode: 0755
|
2023-12-12 15:10:11 +01:00
|
|
|
when: run_once_health_docker_container is not defined
|
2023-11-17 16:53:56 +01:00
|
|
|
|
|
|
|
- name: create health-docker-container.sh
|
|
|
|
copy:
|
|
|
|
src: health-docker-container.sh
|
|
|
|
dest: "{{health_docker_container_folder}}health-docker-container.sh"
|
2023-12-12 15:10:11 +01:00
|
|
|
when: run_once_health_docker_container is not defined
|
2023-11-17 16:53:56 +01:00
|
|
|
|
2024-01-10 11:18:38 +01:00
|
|
|
- name: create health-docker-container.cymais.service
|
|
|
|
template:
|
|
|
|
src: health-docker-container.service.j2
|
|
|
|
dest: /etc/systemd/system/health-docker-container.cymais.service
|
|
|
|
notify: reload health-docker-container.cymais.service
|
2023-12-12 15:10:11 +01:00
|
|
|
when: run_once_health_docker_container is not defined
|
2023-11-17 16:53:56 +01:00
|
|
|
|
2024-01-04 13:27:07 +01:00
|
|
|
- name: set service_name to the name of the current role
|
|
|
|
set_fact:
|
|
|
|
service_name: "{{ role_name }}"
|
|
|
|
when: run_once_health_docker_container is not defined
|
|
|
|
|
|
|
|
- name: "include role for systemd-timer for {{service_name}}"
|
|
|
|
include_role:
|
|
|
|
name: systemd-timer
|
|
|
|
vars:
|
|
|
|
on_calendar: "{{on_calendar_health_docker_container}}"
|
2023-12-12 15:10:11 +01:00
|
|
|
when: run_once_health_docker_container is not defined
|
|
|
|
|
|
|
|
- name: run the health_docker_container tasks once
|
|
|
|
set_fact:
|
|
|
|
run_once_health_docker_container: true
|
|
|
|
when: run_once_health_docker_container is not defined
|