homelab/roles/synapse/templates/synapse.yaml.j2

52 lines
1.5 KiB
Text
Raw Normal View History

server_name: "{{ server_name }}"
2024-10-03 00:29:14 +05:00
listeners:
- port: 8008
tls: false
type: http
x_forwarded: true
resources:
- names: [client, federation]
compress: false
database:
name: psycopg2
args:
user: "{{ postgresql_user }}"
2024-10-03 00:29:14 +05:00
password: "{{ postgresql_password }}"
dbname: "{{ postgresql_dbname }}"
host: "{{ postgresql_host }}"
cp_max: {{ postgresql_conn_max }}
2024-10-03 00:29:14 +05:00
media_store_path: /data/media_store
signing_key_path: /data/{{ server_name }}.signing.key
2024-10-03 00:29:14 +05:00
log_config: /etc/synapse/log.config
report_stats: true
2024-10-04 02:09:16 +05:00
trusted_key_servers:
- server_name: "matrix.org"
2024-10-20 19:58:03 +05:00
{% if turn_uris is defined and turn_shared_secret is defined %}
turn_uris:
{% for uri in turn_uris %}
- {{ uri }}
{% endfor %}
2024-10-04 02:09:16 +05:00
turn_shared_secret: "{{ turn_shared_secret }}"
turn_user_lifetime: 86400000
turn_allow_guests: true
{% endif %}
2024-10-20 19:58:03 +05:00
{% if openid_client_id is defined and openid_client_secret is defined and openid_issuer_url is defined %}
2024-10-20 19:58:03 +05:00
oidc_providers:
- idp_id: "{{ openid_idp_id }}"
idp_name: "{{ openid_idp_name }}"
discover: {{ openid_discover }}
issuer: "{{ openid_issuer_url }}"
client_id: "{{ openid_client_id }}"
2024-10-20 19:58:03 +05:00
client_secret: "{{ openid_client_secret }}"
scopes:
{% for scope in openid_scopes %}
- {{ scope }}
{% endfor %}
2024-10-20 19:58:03 +05:00
user_mapping_provider:
config:
localpart_template: "{{ '{{' }} {{ openid_localpart_template }} {{ '}}' }}"
display_name_template: "{{ '{{' }} {{ openid_display_name_template }} {{ '}}' }}"
{% endif %}