mirror of
https://github.com/luzifer-ansible/docker-compose.git
synced 2024-11-08 13:39:59 +00:00
Use proper boolean, stop timer when disabling
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
a171ae9a44
commit
9040e13587
1 changed files with 12 additions and 11 deletions
|
@ -66,13 +66,13 @@
|
|||
- name: Enable docker-compose service
|
||||
systemd:
|
||||
name: docker-compose.service
|
||||
daemon_reload: yes
|
||||
enabled: yes
|
||||
daemon_reload: true
|
||||
enabled: true
|
||||
|
||||
- name: Restart service if service configuration changed
|
||||
systemd:
|
||||
name: docker-compose.service
|
||||
daemon_reload: yes
|
||||
daemon_reload: true
|
||||
state: restarted
|
||||
when: docker_compose_service.changed and packer_build_name is not defined
|
||||
|
||||
|
@ -114,13 +114,13 @@
|
|||
- name: Enable docker-compose-reload.timer
|
||||
systemd:
|
||||
name: docker-compose-reload.timer
|
||||
daemon_reload: yes
|
||||
enabled: yes
|
||||
daemon_reload: true
|
||||
enabled: true
|
||||
|
||||
- name: Restart docker-compose-reload.timer if it changed
|
||||
systemd:
|
||||
name: docker-compose-reload.timer
|
||||
daemon_reload: yes
|
||||
daemon_reload: true
|
||||
state: restarted
|
||||
when: docker_compose_reload_timer.changed and packer_build_name is not defined
|
||||
|
||||
|
@ -174,22 +174,23 @@
|
|||
- name: Enable docker-clean timer
|
||||
systemd:
|
||||
name: docker-clean.timer
|
||||
daemon_reload: yes
|
||||
enabled: yes
|
||||
daemon_reload: true
|
||||
enabled: true
|
||||
when: docker_compose_add_cleanjob
|
||||
|
||||
- name: Restart docker-clean.timer if it changed
|
||||
systemd:
|
||||
name: docker-clean.timer
|
||||
daemon_reload: yes
|
||||
daemon_reload: true
|
||||
state: restarted
|
||||
when: docker_compose_clean_timer is defined and docker_compose_clean_timer.changed and packer_build_name is not defined and docker_compose_add_cleanjob
|
||||
|
||||
- name: Deactivate docker-clean timer
|
||||
systemd:
|
||||
name: docker-clean.timer
|
||||
daemon_reload: yes
|
||||
enabled: no
|
||||
daemon_reload: true
|
||||
enabled: false
|
||||
state: stopped
|
||||
when: not docker_compose_add_cleanjob
|
||||
|
||||
- name: Uninstall docker-clean components
|
||||
|
|
Loading…
Reference in a new issue