Matrix Docker Ansible eploy
Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 

251 righe
15 KiB

  1. # SPDX-FileCopyrightText: 2020 - 2022 MDAD project contributors
  2. # SPDX-FileCopyrightText: 2020 - 2024 Slavi Pantaleev
  3. # SPDX-FileCopyrightText: 2020 Marcel Partap
  4. # SPDX-FileCopyrightText: 2020 Matt Cengia
  5. # SPDX-FileCopyrightText: 2021 Aaron Raimist
  6. # SPDX-FileCopyrightText: 2021 Ahmad Haghighi
  7. # SPDX-FileCopyrightText: 2021 boris runakov
  8. # SPDX-FileCopyrightText: 2022 Marko Weltzer
  9. # SPDX-FileCopyrightText: 2022 Nikita Chernyi
  10. # SPDX-FileCopyrightText: 2023 Samuel Meenzen
  11. # SPDX-FileCopyrightText: 2024 - 2025 Suguru Hirahara
  12. #
  13. # SPDX-License-Identifier: AGPL-3.0-or-later
  14. ---
  15. # ma1sd is a Federated Matrix Identity Server
  16. # Project source code URL: https://github.com/ma1uta/ma1sd
  17. matrix_ma1sd_enabled: true
  18. matrix_ma1sd_scheme: https
  19. matrix_ma1sd_hostname: ''
  20. matrix_ma1sd_container_image_self_build: false
  21. matrix_ma1sd_container_image_self_build_repo: "https://github.com/ma1uta/ma1sd.git"
  22. matrix_ma1sd_container_image_self_build_branch: "{{ matrix_ma1sd_version }}"
  23. # renovate: datasource=docker depName=ma1uta/ma1sd
  24. matrix_ma1sd_version: "2.5.0"
  25. matrix_ma1sd_docker_image: "{{ matrix_ma1sd_docker_image_registry_prefix }}ma1uta/ma1sd:{{ matrix_ma1sd_version }}"
  26. matrix_ma1sd_docker_image_registry_prefix: "{{ 'localhost/' if matrix_ma1sd_container_image_self_build else matrix_ma1sd_docker_image_registry_prefix_upstream }}"
  27. matrix_ma1sd_docker_image_registry_prefix_upstream: "{{ matrix_ma1sd_docker_image_registry_prefix_upstream_default }}"
  28. matrix_ma1sd_docker_image_registry_prefix_upstream_default: "docker.io/"
  29. matrix_ma1sd_docker_image_force_pull: "{{ matrix_ma1sd_docker_image.endswith(':latest') }}"
  30. matrix_ma1sd_base_path: "{{ matrix_base_data_path }}/ma1sd"
  31. # We need the docker src directory to be named ma1sd. See: https://github.com/spantaleev/matrix-docker-ansible-deploy/pull/588
  32. matrix_ma1sd_docker_src_files_path: "{{ matrix_ma1sd_base_path }}/docker-src/ma1sd"
  33. matrix_ma1sd_config_path: "{{ matrix_ma1sd_base_path }}/config"
  34. matrix_ma1sd_data_path: "{{ matrix_ma1sd_base_path }}/data"
  35. matrix_ma1sd_container_port: 8090
  36. # Controls whether the matrix-ma1sd container exposes its HTTP port (tcp/{{ matrix_ma1sd_container_port }} in the container).
  37. #
  38. # Takes an "<ip>:<port>" or "<port>" value (e.g. "127.0.0.1:8090"), or empty string to not expose.
  39. matrix_ma1sd_container_http_host_bind_port: ''
  40. # A list of extra arguments to pass to the container
  41. matrix_ma1sd_container_extra_arguments: []
  42. # List of systemd services that matrix-ma1sd.service depends on
  43. matrix_ma1sd_systemd_required_services_list: "{{ matrix_ma1sd_systemd_required_services_list_default + matrix_ma1sd_systemd_required_services_list_auto + matrix_ma1sd_systemd_required_services_list_custom }}"
  44. matrix_ma1sd_systemd_required_services_list_default: "{{ [devture_systemd_docker_base_docker_service_name] if devture_systemd_docker_base_docker_service_name else [] }}"
  45. matrix_ma1sd_systemd_required_services_list_auto: []
  46. matrix_ma1sd_systemd_required_services_list_custom: []
  47. # List of systemd services that matrix-ma1sd.service wants
  48. matrix_ma1sd_systemd_wanted_services_list: "{{ matrix_ma1sd_systemd_wanted_services_list_default + matrix_ma1sd_systemd_wanted_services_list_auto + matrix_ma1sd_systemd_wanted_services_list_custom }}"
  49. matrix_ma1sd_systemd_wanted_services_list_default: []
  50. matrix_ma1sd_systemd_wanted_services_list_auto: []
  51. matrix_ma1sd_systemd_wanted_services_list_custom: []
  52. # The base container network. It will be auto-created by this role if it doesn't exist already.
  53. matrix_ma1sd_container_network: ""
  54. # A list of additional container networks that matrix-ma1sd would be connected to.
  55. # The playbook does not create these networks, so make sure they already exist.
  56. #
  57. # Use this to expose matrix-ma1sd to another docker network, that matrix-ma1sd might have to reach for authentication (e.g. an ldap instance)
  58. matrix_ma1sd_container_additional_networks: "{{ matrix_ma1sd_container_additional_networks_auto + matrix_ma1sd_container_additional_networks_custom }}"
  59. matrix_ma1sd_container_additional_networks_auto: []
  60. matrix_ma1sd_container_additional_networks_custom: []
  61. # matrix_ma1sd_container_labels_traefik_enabled controls whether labels to assist a Traefik reverse-proxy will be attached to the container.
  62. # See `../templates/labels.j2` for details.
  63. #
  64. # To inject your own other container labels, see `matrix_ma1sd_container_labels_additional_labels`.
  65. matrix_ma1sd_container_labels_traefik_enabled: true
  66. matrix_ma1sd_container_labels_traefik_docker_network: "{{ matrix_ma1sd_container_network }}"
  67. matrix_ma1sd_container_labels_traefik_entrypoints: web-secure
  68. matrix_ma1sd_container_labels_traefik_tls_certResolver: default # noqa var-naming
  69. # Controls whether labels will be added that expose ma1sd's /_matrix/identity endpoints
  70. matrix_ma1sd_container_labels_matrix_identity_enabled: "{{ matrix_ma1sd_container_labels_traefik_enabled }}"
  71. matrix_ma1sd_container_labels_matrix_identity_hostname: "{{ matrix_ma1sd_hostname }}"
  72. matrix_ma1sd_container_labels_matrix_identity_path_prefix: "/_matrix/identity"
  73. matrix_ma1sd_container_labels_matrix_identity_traefik_rule: "Host(`{{ matrix_ma1sd_container_labels_matrix_identity_hostname }}`) && PathPrefix(`{{ matrix_ma1sd_container_labels_matrix_identity_path_prefix }}`)"
  74. matrix_ma1sd_container_labels_matrix_identity_traefik_priority: 0
  75. matrix_ma1sd_container_labels_matrix_identity_traefik_entrypoints: "{{ matrix_ma1sd_container_labels_traefik_entrypoints }}"
  76. matrix_ma1sd_container_labels_matrix_identity_traefik_tls: "{{ matrix_ma1sd_container_labels_matrix_identity_traefik_entrypoints != 'web' }}"
  77. matrix_ma1sd_container_labels_matrix_identity_traefik_tls_certResolver: "{{ matrix_ma1sd_container_labels_traefik_tls_certResolver }}" # noqa var-naming
  78. # Controls whether labels will be added that expose ma1sd's /_matrix/client/VERSION/user_directory/search endpoint
  79. matrix_ma1sd_container_labels_matrix_client_user_directory_search_enabled: "{{ matrix_ma1sd_container_labels_traefik_enabled }}"
  80. matrix_ma1sd_container_labels_matrix_client_user_directory_search_hostname: "{{ matrix_ma1sd_hostname }}"
  81. matrix_ma1sd_container_labels_matrix_client_user_directory_search_path_regexp: "/_matrix/client/(?P<version>(r0|v3))/user_directory/search"
  82. matrix_ma1sd_container_labels_matrix_client_user_directory_search_traefik_rule: "Host(`{{ matrix_ma1sd_container_labels_matrix_client_user_directory_search_hostname }}`) && PathRegexp(`{{ matrix_ma1sd_container_labels_matrix_client_user_directory_search_path_regexp }}`)"
  83. matrix_ma1sd_container_labels_matrix_client_user_directory_search_traefik_priority: 0
  84. matrix_ma1sd_container_labels_matrix_client_user_directory_search_traefik_entrypoints: "{{ matrix_ma1sd_container_labels_traefik_entrypoints }}"
  85. matrix_ma1sd_container_labels_matrix_client_user_directory_search_traefik_tls: "{{ matrix_ma1sd_container_labels_matrix_client_user_directory_search_traefik_entrypoints != 'web' }}"
  86. matrix_ma1sd_container_labels_matrix_client_user_directory_search_traefik_tls_certResolver: "{{ matrix_ma1sd_container_labels_traefik_tls_certResolver }}" # noqa var-naming
  87. # Controls whether labels will be added that expose ma1sd's /_matrix/client/VERSION/register/TYPE/requestToken endpoints
  88. # This allows another service to control registrations involving 3PIDs.
  89. # To learn more, see: https://github.com/ma1uta/ma1sd/blob/master/docs/features/registration.md
  90. matrix_ma1sd_container_labels_matrix_client_3pid_registration_enabled: false
  91. matrix_ma1sd_container_labels_matrix_client_3pid_registration_hostname: "{{ matrix_ma1sd_hostname }}"
  92. matrix_ma1sd_container_labels_matrix_client_3pid_registration_path_regexp: "/_matrix/client/(?P<version>(r0|v3))/register/(?P<type>(email|msisdn))/requestToken"
  93. matrix_ma1sd_container_labels_matrix_client_3pid_registration_traefik_rule: "Host(`{{ matrix_ma1sd_container_labels_matrix_client_3pid_registration_hostname }}`) && PathRegexp(`{{ matrix_ma1sd_container_labels_matrix_client_3pid_registration_path_regexp }}`)"
  94. matrix_ma1sd_container_labels_matrix_client_3pid_registration_traefik_priority: 0
  95. matrix_ma1sd_container_labels_matrix_client_3pid_registration_traefik_entrypoints: "{{ matrix_ma1sd_container_labels_traefik_entrypoints }}"
  96. matrix_ma1sd_container_labels_matrix_client_3pid_registration_traefik_tls: "{{ matrix_ma1sd_container_labels_matrix_client_3pid_registration_traefik_entrypoints != 'web' }}"
  97. matrix_ma1sd_container_labels_matrix_client_3pid_registration_traefik_tls_certResolver: "{{ matrix_ma1sd_container_labels_traefik_tls_certResolver }}" # noqa var-naming
  98. # matrix_ma1sd_container_labels_additional_labels contains a multiline string with additional labels to add to the container label file.
  99. # See `../templates/labels.j2` for details.
  100. #
  101. # Example:
  102. # matrix_ma1sd_container_labels_additional_labels: |
  103. # my.label=1
  104. # another.label="here"
  105. matrix_ma1sd_container_labels_additional_labels: ''
  106. # Your identity server is private by default.
  107. # To ensure maximum discovery, you can make your identity server
  108. # also forward lookups to the central matrix.org Identity server
  109. # (at the cost of potentially leaking all your contacts information).
  110. # Enabling this is discouraged. Learn more here: https://github.com/ma1uta/ma1sd/blob/master/docs/features/identity.md#lookups
  111. matrix_ma1sd_matrixorg_forwarding_enabled: false
  112. # Database-related configuration fields.
  113. #
  114. # To use SQLite, stick to these defaults.
  115. #
  116. # To use Postgres:
  117. # - change the engine (`matrix_ma1sd_database_engine: 'postgres'`)
  118. # - adjust your database credentials via the `matrix_ma1sd_database_*` variables
  119. matrix_ma1sd_database_engine: 'sqlite'
  120. matrix_ma1sd_sqlite_database_path_local: "{{ matrix_ma1sd_data_path }}/ma1sd.db"
  121. matrix_ma1sd_sqlite_database_path_in_container: "/var/ma1sd/ma1sd.db"
  122. matrix_ma1sd_database_username: 'matrix_ma1sd'
  123. matrix_ma1sd_database_password: 'some-password'
  124. matrix_ma1sd_database_hostname: ''
  125. matrix_ma1sd_database_port: 5432
  126. matrix_ma1sd_database_name: 'matrix_ma1sd'
  127. matrix_ma1sd_database_connection_string: 'postgresql://{{ matrix_ma1sd_database_username }}:{{ matrix_ma1sd_database_password }}@{{ matrix_ma1sd_database_hostname }}:{{ matrix_ma1sd_database_port }}/{{ matrix_ma1sd_database_name }}'
  128. # ma1sd has several supported identity stores.
  129. # One of them is storing identities directly in Synapse's database.
  130. # Learn more here: https://github.com/ma1uta/ma1sd/blob/master/docs/stores/synapse.md
  131. matrix_ma1sd_synapsesql_enabled: false
  132. matrix_ma1sd_synapsesql_type: ""
  133. matrix_ma1sd_synapsesql_connection: ""
  134. # Setting up email-sending settings is required for using ma1sd.
  135. matrix_ma1sd_threepid_medium_email_identity_from: "matrix@{{ matrix_domain }}"
  136. matrix_ma1sd_threepid_medium_email_connectors_smtp_host: ""
  137. matrix_ma1sd_threepid_medium_email_connectors_smtp_port: 587
  138. matrix_ma1sd_threepid_medium_email_connectors_smtp_tls: 1
  139. matrix_ma1sd_threepid_medium_email_connectors_smtp_login: ""
  140. matrix_ma1sd_threepid_medium_email_connectors_smtp_password: ""
  141. # DNS overwrites are useful for telling ma1sd how it can reach the homeserver directly.
  142. # Useful when reverse-proxying certain URLs (e.g. `/_matrix/client/r0/user_directory/search`) to ma1sd,
  143. # so that ma1sd can rewrite the original URL to one that would reach the homeserver.
  144. matrix_ma1sd_dns_overwrite_enabled: false
  145. matrix_ma1sd_dns_overwrite_homeserver_client_name: "{{ matrix_server_fqn_matrix }}"
  146. matrix_ma1sd_dns_overwrite_homeserver_client_value: ""
  147. # Override the default session templates
  148. # To use this, fill in the template variables with the full desired template as a multi-line YAML variable
  149. #
  150. # More info:
  151. # https://github.com/ma1uta/ma1sd/blob/master/docs/threepids/session/session-views.md
  152. matrix_ma1sd_view_session_custom_templates_enabled: false
  153. # Defaults to: https://github.com/ma1uta/ma1sd/blob/master/src/main/resources/templates/session/tokenSubmitSuccess.html
  154. matrix_ma1sd_view_session_custom_onTokenSubmit_success_template: "" # noqa var-naming
  155. # Defaults to: https://github.com/ma1uta/ma1sd/blob/master/src/main/resources/templates/session/tokenSubmitFailure.html
  156. matrix_ma1sd_view_session_custom_onTokenSubmit_failure_template: "" # noqa var-naming
  157. # Override the default email templates
  158. # To use this, fill in the template variables with the full desired template as a multi-line YAML variable
  159. #
  160. # More info:
  161. # https://github.com/ma1uta/ma1sd/blob/master/docs/threepids/notification/template-generator.md
  162. # https://github.com/ma1uta/ma1sd/tree/master/src/main/resources/threepids/email
  163. matrix_ma1sd_threepid_medium_email_custom_templates_enabled: false
  164. # Defaults to: https://github.com/ma1uta/ma1sd/blob/master/src/main/resources/threepids/email/invite-template.eml
  165. matrix_ma1sd_threepid_medium_email_custom_invite_template: ""
  166. # Defaults to: https://github.com/ma1uta/ma1sd/blob/master/src/main/resources/threepids/email/validate-template.eml
  167. matrix_ma1sd_threepid_medium_email_custom_session_validation_template: ""
  168. # Defaults to: https://github.com/ma1uta/ma1sd/blob/master/src/main/resources/threepids/email/unbind-notification.eml
  169. matrix_ma1sd_threepid_medium_email_custom_session_unbind_notification_template: ""
  170. # Defaults to: https://github.com/ma1uta/ma1sd/blob/master/src/main/resources/threepids/email/mxid-template.eml
  171. matrix_ma1sd_threepid_medium_email_custom_matrixid_template: ""
  172. matrix_ma1sd_self_check_endpoint_url: "{{ matrix_ma1sd_scheme }}://{{ matrix_ma1sd_hostname }}/_matrix/identity/api/v1"
  173. # Controls whether the self-check feature should validate SSL certificates.
  174. matrix_ma1sd_self_check_validate_certificates: true
  175. # Controls ma1sd logging verbosity for troubleshooting.
  176. #
  177. # See: https://github.com/ma1uta/ma1sd/blob/master/docs/troubleshooting.md#increase-verbosity
  178. matrix_ma1sd_verbose_logging: false
  179. # Setting up support for API prefixes
  180. matrix_ma1sd_v1_enabled: true
  181. matrix_ma1sd_v2_enabled: true
  182. # Fix for missing 3PIDS bug
  183. matrix_ma1sd_hashing_enabled: true
  184. # Default ma1sd configuration template which covers the generic use case.
  185. # You can customize it by controlling the various variables inside it.
  186. #
  187. # For a more advanced customization, you can extend the default (see `matrix_ma1sd_configuration_extension_yaml`)
  188. # or completely replace this variable with your own template.
  189. matrix_ma1sd_configuration_yaml: "{{ lookup('template', 'templates/ma1sd.yaml.j2') }}"
  190. matrix_ma1sd_configuration_extension_yaml: |
  191. # Your custom YAML configuration for ma1sd goes here.
  192. # This configuration extends the default starting configuration (`matrix_ma1sd_configuration_yaml`).
  193. #
  194. # You can override individual variables from the default configuration, or introduce new ones.
  195. #
  196. # If you need something more special, you can take full control by
  197. # completely redefining `matrix_ma1sd_configuration_yaml`.
  198. #
  199. # Example configuration extension follows:
  200. #
  201. # ldap:
  202. # enabled: true
  203. # connection:
  204. # host: ldapHostnameOrIp
  205. # tls: false
  206. # port: 389
  207. # baseDNs: ['OU=Users,DC=example,DC=org']
  208. # bindDn: CN=My Ma1sd User,OU=Users,DC=example,DC=org
  209. # bindPassword: TheUserPassword
  210. matrix_ma1sd_configuration_extension: "{{ matrix_ma1sd_configuration_extension_yaml | from_yaml if matrix_ma1sd_configuration_extension_yaml | from_yaml is mapping else {} }}"
  211. # Holds the final ma1sd configuration (a combination of the default and its extension).
  212. # You most likely don't need to touch this variable. Instead, see `matrix_ma1sd_configuration_yaml`.
  213. matrix_ma1sd_configuration: "{{ matrix_ma1sd_configuration_yaml | from_yaml | combine(matrix_ma1sd_configuration_extension, recursive=True) }}"