[refactor] turn homeserver.yaml into template

This commit is contained in:
Nico Schottelius 2024-02-21 18:02:22 +09:00
parent cde72ad340
commit 428e2065b2
4 changed files with 43 additions and 5 deletions

View file

@ -0,0 +1,9 @@
- name: Add docker-compose
hosts: runa
tasks:
- name: Add docker-compose
include_role:
name: docker-compose
tags:
- docker
when: docker_compose or matrix_service

View file

@ -0,0 +1,9 @@
- name: Configure RUNA Matrix VMs
hosts: runa
tasks:
- name: SSL Certs
include_role:
name: ssl-certificates
tags:
- ssl
when: has_ssl_certificates

View file

@ -15,7 +15,6 @@
tags:
- nginx
- dir
- name: Create nginx config
ansible.builtin.template:
src: "nginx/synapse.conf"
@ -25,7 +24,28 @@
tags:
- nginx
- synapse
- name: Create config dir
ansible.builtin.file:
path: /home/{{ ansible_user }}/docker_compose/{{ matrix_service }}/config
state: directory
owner: "{{ ansible_user }}"
mode: '0755'
tags:
- synapse
- dir
- name: Create homeserver configuration
ansible.builtin.template:
src: "synapse/homeserver.yaml"
dest: /home/{{ ansible_user }}/docker_compose/{{ matrix_service }}/config/synapse-worker-{{ item }}.yaml
owner: "{{ ansible_user }}"
mode: '0644'
tags:
- log
- synapse
loop:
- generic
- federation
- sync
- name: Create worker configurations
ansible.builtin.template:
src: "synapse/synapse-worker.yaml"

View file

@ -2332,9 +2332,9 @@ oidc_providers:
scopes: ["openid", "profile"]
user_mapping_provider:
config:
localpart_template: "{{ user.preferred_username }}"
display_name_template: "{{ user.name }}"
subject_template: "{{ user.preferred_username }}"
localpart_template: "{{ '{{' }} user.preferred_username {{ '}}' }}"
display_name_template: "{{ '{{' }} user.name {{ '}}' }}"
subject_template: "{{ '{{' }} user.preferred_username {{ '}}' }}"
backchannel_logout_enabled: true
password_config: