fix(authentik): set proper ownership and permissions for media and custom-templates dirs
ansible-core-net / deploy (push) Successful in 21s
ansible-core-net / deploy (push) Successful in 21s
This commit is contained in:
1 parent
10cf792e4e
commit
172614e421
1 file changed
+10
-9
@@ -1,17 +1,17 @@
|
|||||||
---
|
---
|
||||||
- name: Создать каталоги для сервиса Authentik
|
- name: Создать каталоги для сервиса Authentik
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "{{ item }}"
|
path: "{{ item.path }}"
|
||||||
state: directory
|
state: directory
|
||||||
owner: root
|
owner: "{{ item.owner | default('root') }}"
|
||||||
group: root
|
group: "{{ item.group | default('root') }}"
|
||||||
mode: "0750"
|
mode: "{{ item.mode | default('0750') }}"
|
||||||
loop:
|
loop:
|
||||||
- "{{ authentik_dir }}"
|
- { path: "{{ authentik_dir }}", mode: "0755" }
|
||||||
- "{{ authentik_dir }}/db"
|
- { path: "{{ authentik_dir }}/db", mode: "0700" }
|
||||||
- "{{ authentik_dir }}/redis"
|
- { path: "{{ authentik_dir }}/redis", mode: "0700" }
|
||||||
- "{{ authentik_dir }}/media"
|
- { path: "{{ authentik_dir }}/media", owner: "1000", group: "1000", mode: "0775" }
|
||||||
- "{{ authentik_dir }}/custom-templates"
|
- { path: "{{ authentik_dir }}/custom-templates", owner: "1000", group: "1000", mode: "0775" }
|
||||||
|
|
||||||
- name: Проверить наличие обязательных секретов Authentik
|
- name: Проверить наличие обязательных секретов Authentik
|
||||||
ansible.builtin.assert:
|
ansible.builtin.assert:
|
||||||
@@ -33,3 +33,4 @@
|
|||||||
ansible.builtin.command: docker compose -f {{ authentik_dir }}/compose.yaml up -d --remove-orphans
|
ansible.builtin.command: docker compose -f {{ authentik_dir }}/compose.yaml up -d --remove-orphans
|
||||||
register: compose_up
|
register: compose_up
|
||||||
changed_when: "'Started' in compose_up.stderr or 'Created' in compose_up.stderr or 'Recreated' in compose_up.stderr or 'Pulled' in compose_up.stderr"
|
changed_when: "'Started' in compose_up.stderr or 'Created' in compose_up.stderr or 'Recreated' in compose_up.stderr or 'Pulled' in compose_up.stderr"
|
||||||
|
|
||||||
Reference in new issue
Block a user