From 53cf0e18a4ee8d4eab691c78884c83e019f066e2 Mon Sep 17 00:00:00 2001 From: Charles Wright Date: Thu, 4 Aug 2022 13:32:01 -0500 Subject: [PATCH] Actually make the data dir writable this time --- roles/matrix-conduit/tasks/setup_conduit.yml | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/roles/matrix-conduit/tasks/setup_conduit.yml b/roles/matrix-conduit/tasks/setup_conduit.yml index 17738b176..25632c805 100644 --- a/roles/matrix-conduit/tasks/setup_conduit.yml +++ b/roles/matrix-conduit/tasks/setup_conduit.yml @@ -1,26 +1,20 @@ --- -- name: Ensure Conduit paths exist +- name: Ensure Conduit config path exists file: - path: "{{ item.path }}" + path: "{{ matrix_conduit_config_path }}" state: directory mode: 0750 owner: "{{ matrix_user_username }}" group: "{{ matrix_user_groupname }}" - with_items: - - {path: "{{ matrix_conduit_config_path }}", when: true} - - {path: "{{ matrix_conduit_data_path }}", when: true} - when: "matrix_conduit_enabled|bool and item.when" + when: "matrix_conduit_enabled|bool" -# We do this as a separate task, because: -# - we'd like to do it for the data path only, not for the base path (which contains root-owned environment variable files we'd like to leave as-is) -# - matrix-postgres does something similar -- name: Ensure Conduit data path ownership is correct +- name: Ensure Conduit data path exists file: path: "{{ matrix_conduit_data_path }}" state: directory + mode: 0770 owner: "{{ matrix_user_username }}" group: "{{ matrix_user_groupname }}" - recurse: true - when: matrix_conduit_enabled|bool + when: "matrix_conduit_enabled|bool" - import_tasks: "{{ role_path }}/tasks/conduit/setup.yml"