From 338c12c6874aadc69495b3dfa3c258c7e48b948e Mon Sep 17 00:00:00 2001 From: Markus Hauschild Date: Wed, 6 Nov 2024 19:08:10 +0100 Subject: [PATCH] authentik: split handling or service and reload timer --- roles/authentik/handlers/main.yml | 3 +++ roles/authentik/tasks/main.yml | 15 ++++++++++----- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/roles/authentik/handlers/main.yml b/roles/authentik/handlers/main.yml index 07c6c69..1ec8a95 100644 --- a/roles/authentik/handlers/main.yml +++ b/roles/authentik/handlers/main.yml @@ -6,6 +6,9 @@ - name: Restart authentik service: name=authentik state=restarted +- name: Restart authentik-reload + service: name=authentik-reload state=restarted + - name: Restart nginx service: name=nginx state=restarted diff --git a/roles/authentik/tasks/main.yml b/roles/authentik/tasks/main.yml index 762fbc6..df7b6c8 100644 --- a/roles/authentik/tasks/main.yml +++ b/roles/authentik/tasks/main.yml @@ -37,15 +37,20 @@ notify: Restart nginx - name: Systemd unit for authentik - template: src=authentik{{ item }}.j2 dest=/etc/systemd/system/authentik{{ item }} - with_items: - - ".service" - - "-reload.service" - - "-reload.timer" + template: src=authentik.service.j2 dest=/etc/systemd/system/authentik.service notify: - Reload systemd - Restart authentik +- name: Systemd unit for authentik-reload + template: src=authentik-reload.{{ item }}.j2 dest=/etc/systemd/system/authentik-reload.{{ item }} + with_items: + - "service" + - "timer" + notify: + - Reload systemd + - Restart authentik-reload + - name: Start the authentik service service: name=authentik state=started enabled=yes