You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

13 lines
471 B

- name: Run service actions
loop: "{{ systemd.services }}"
systemd:
name: '{{ item.name }}'
enabled: "{% if item.enabled|default(false) %}yes{% else %}no{% endif %}"
state: "{{ item.action }}"
daemon_reload: "{% if item.daemon_reload|default(false) %}yes{% else %}no{% endif %}"
- name: Restart services
loop: "{{ systemd.services }}"
systemd:
name: '{{ item.name }}'
state: "restarted"
daemon_reload: true