2018-12-06 02:59:47 +08:00
|
|
|
---
|
2024-02-14 18:14:02 +08:00
|
|
|
- name: Service handler
|
2018-12-06 02:59:47 +08:00
|
|
|
# We use the systemd module here so we can use the daemon_reload feature,
|
|
|
|
# since we're shipping the .service file ourselves
|
2024-02-14 18:14:02 +08:00
|
|
|
ansible.builtin.systemd:
|
2018-12-06 02:59:47 +08:00
|
|
|
name: "{{ item }}"
|
|
|
|
daemon_reload: true
|
|
|
|
enabled: true
|
|
|
|
state: restarted
|
|
|
|
with_items:
|
|
|
|
- 'alertmanager'
|
2019-08-23 02:29:40 +08:00
|
|
|
- 'prometheus'
|
2020-04-17 00:17:12 +08:00
|
|
|
when: not docker2podman | default(False) | bool
|