ansible-edda/playbooks/roles/services/include/tasks/daemon_reload/main.yml

17 lines
583 B
YAML
Raw Normal View History

2022-12-18 23:43:40 +01:00
---
2022-12-10 21:39:04 +01:00
- name: "daemon_reload : {{ services_service_name }} : set variables"
ansible.builtin.import_tasks: "../vars.yml"
- name: "daemon_reload : {{ services_service_name }} : check if home exists"
ansible.builtin.stat:
path: "{{ services_service_user_home }}"
register: services_include_daemon_reload_user_home
- name: "daemon_reload : {{ services_service_name }} : systemd daemon reload"
become_user: "{{ services_service_user_name }}"
ansible.builtin.systemd:
daemon_reload: true
scope: "user"
when:
services_include_daemon_reload_user_home.stat.exists