renew_nomad_certificates/handlers/main.yml
Bertrand Lanson a4d952ef1a
All checks were successful
test / Linting (push) Successful in 10s
test / Molecule tests (default, debian12) (push) Successful in 1m8s
test / Molecule tests (default, debian11) (push) Successful in 1m9s
test / Molecule tests (default, ubuntu2004) (push) Successful in 1m20s
test / Molecule tests (default, ubuntu2204) (push) Successful in 1m23s
test / Molecule tests (with_custom_config, debian11) (push) Successful in 1m6s
test / Molecule tests (with_custom_config, debian12) (push) Successful in 1m9s
test / Molecule tests (with_custom_config, ubuntu2004) (push) Successful in 1m21s
test / Molecule tests (with_custom_config, ubuntu2204) (push) Successful in 1m21s
feat: add become, add vagrant tests, fix#1
2023-12-02 16:48:14 +01:00

23 lines
553 B
YAML

---
# handlers file for renew_nomad_certificates
- name: "Reload service file"
ansible.builtin.systemd:
daemon_reload: true
become: true
listen: "systemctl-daemon-reload"
- name: "Enable nomad-certs service"
ansible.builtin.service:
name: nomad-certs
enabled: true
become: true
listen: "systemctl-enable-nomad-certs"
- name: "Start nomad-certs service"
ansible.builtin.service:
name: nomad-certs
state: restarted
listen: "systemctl-restart-nomad-certs"
when: renew_nomad_certificates_start_service
become: true