diff --git a/roles/manage-server/defaults/main.yml b/roles/manage-server/defaults/main.yml index 3cac3d3ac..577953c3e 100644 --- a/roles/manage-server/defaults/main.yml +++ b/roles/manage-server/defaults/main.yml @@ -19,3 +19,10 @@ manage_manage_provision_samlsp_sp_cert: "" manage_manage_provision_samlsp_trusted_proxy: false manage_manage_provision_samlsp_sign: false manage_provision_push: false +manage_tabs_enabled: + - saml20_idp + - saml20_sp + - oidc10_rp + - oauth20_rs + - single_tenant_template + - provisioning diff --git a/roles/manage-server/tasks/main.yml b/roles/manage-server/tasks/main.yml index 76f6d5056..649962166 100644 --- a/roles/manage-server/tasks/main.yml +++ b/roles/manage-server/tasks/main.yml @@ -39,14 +39,27 @@ notify: - "restart manage" -- name: copy and template metadata configuration +- name: copy metadata configuration template: - src: "{{ item }}" - dest: '{{ manage_dir }}/metadata_configuration/{{ item | basename | regex_replace("\.j2","") }}' + src: "metadata_configuration/{{ item }}.schema.json.j2" + dest: "{{ manage_dir }}/metadata_configuration/{{ item }}.schema.json" + owner: manage + group: manage + mode: "0640" + with_items: + - "{{ manage_tabs_enabled }}" + notify: + - "restart manage" + +- name: copy metadata templates + copy: + src: "metadata_templates/{{ item }}.template.json" + dest: "{{ manage_dir }}/metadata_templates/{{ item }}.template.json" owner: manage group: manage - mode: 0640 - with_fileglob: "metadata_configuration/*.j2" + mode: "0640" + with_items: + - "{{ manage_tabs_enabled }}" notify: - "restart manage" @@ -56,10 +69,9 @@ dest: "{{ manage_dir }}" owner: manage group: manage - mode: 0640 + mode: "0640" with_items: - metadata_export - - metadata_templates notify: - "restart manage" diff --git a/roles/manage-server/files/metadata_configuration/oauth20_rs.schema.json.j2 b/roles/manage-server/templates/metadata_configuration/oauth20_rs.schema.json.j2 similarity index 100% rename from roles/manage-server/files/metadata_configuration/oauth20_rs.schema.json.j2 rename to roles/manage-server/templates/metadata_configuration/oauth20_rs.schema.json.j2 diff --git a/roles/manage-server/files/metadata_configuration/oidc10_rp.schema.json.j2 b/roles/manage-server/templates/metadata_configuration/oidc10_rp.schema.json.j2 similarity index 100% rename from roles/manage-server/files/metadata_configuration/oidc10_rp.schema.json.j2 rename to roles/manage-server/templates/metadata_configuration/oidc10_rp.schema.json.j2 diff --git a/roles/manage-server/files/metadata_configuration/provisioning.schema.json.j2 b/roles/manage-server/templates/metadata_configuration/provisioning.schema.json.j2 similarity index 100% rename from roles/manage-server/files/metadata_configuration/provisioning.schema.json.j2 rename to roles/manage-server/templates/metadata_configuration/provisioning.schema.json.j2 diff --git a/roles/manage-server/files/metadata_configuration/saml20_idp.schema.json.j2 b/roles/manage-server/templates/metadata_configuration/saml20_idp.schema.json.j2 similarity index 100% rename from roles/manage-server/files/metadata_configuration/saml20_idp.schema.json.j2 rename to roles/manage-server/templates/metadata_configuration/saml20_idp.schema.json.j2 diff --git a/roles/manage-server/files/metadata_configuration/saml20_sp.schema.json.j2 b/roles/manage-server/templates/metadata_configuration/saml20_sp.schema.json.j2 similarity index 100% rename from roles/manage-server/files/metadata_configuration/saml20_sp.schema.json.j2 rename to roles/manage-server/templates/metadata_configuration/saml20_sp.schema.json.j2 diff --git a/roles/manage-server/files/metadata_configuration/single_tenant_template.schema.json.j2 b/roles/manage-server/templates/metadata_configuration/single_tenant_template.schema.json.j2 similarity index 100% rename from roles/manage-server/files/metadata_configuration/single_tenant_template.schema.json.j2 rename to roles/manage-server/templates/metadata_configuration/single_tenant_template.schema.json.j2