Matrix Docker Ansible eploy
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

6058 line
324 KiB

  1. # SPDX-FileCopyrightText: 2019 MDAD Team and contributors
  2. #
  3. # SPDX-License-Identifier: AGPL-3.0-or-later
  4. ---
  5. # This variables file wires together the various components (roles) used by the playbook.
  6. #
  7. # Roles used by playbook are pretty minimal and kept independent of one another as much as possible.
  8. # To deliver a turnkey fully-featured Matrix server, this playbook needs
  9. # to connect them all together. It does so by overriding role variables.
  10. #
  11. # You can also override ANY variable (seen here or in any given role),
  12. # by re-defining it in your own configuration file (`inventory/host_vars/matrix.example.com`).
  13. ########################################################################
  14. # #
  15. # Playbook #
  16. # #
  17. ########################################################################
  18. # Controls whether to install Docker or not
  19. # Also see `devture_docker_sdk_for_python_installation_enabled`.
  20. matrix_playbook_docker_installation_enabled: true
  21. matrix_playbook_docker_installation_daemon_options: "{{ matrix_playbook_docker_installation_daemon_options_auto | combine(matrix_playbook_docker_installation_daemon_options_custom, recursive=True) }}"
  22. matrix_playbook_docker_installation_daemon_options_auto:
  23. experimental: "{{ devture_systemd_docker_base_ipv6_enabled }}"
  24. ip6tables: "{{ devture_systemd_docker_base_ipv6_enabled }}"
  25. matrix_playbook_docker_installation_daemon_options_custom: {}
  26. # Controls whether to attach Traefik labels to services.
  27. # This is separate from `traefik_enabled`, because you may wish to disable Traefik installation by the playbook,
  28. # yet still use Traefik installed in another way.
  29. matrix_playbook_traefik_labels_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  30. matrix_playbook_reverse_proxy_container_network: "{{ traefik_container_network if traefik_enabled else 'traefik' }}"
  31. matrix_playbook_reverse_proxy_hostname: "{{ traefik_identifier if traefik_enabled else 'traefik' }}"
  32. matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled: "{{ traefik_config_http_middlewares_compression_enabled if (traefik_enabled and traefik_config_http_middlewares_compression_enabled) else false }}"
  33. matrix_playbook_reverse_proxy_traefik_middleware_compression_name: "{{ (traefik_config_http_middlewares_compression_middleware_name + '@file') if traefik_enabled else '' }}"
  34. # A separate Matrix Federation entrypoint is always enabled, unless the federation port matches one of the ports for existing (default) entrypoints
  35. matrix_playbook_public_matrix_federation_api_traefik_entrypoint_enabled: "{{ matrix_federation_public_port not in [traefik_config_entrypoint_web_port, traefik_config_entrypoint_web_secure_port] }}"
  36. # We only enable HTTP/3 on the federation entrypoint if the main web-secure entrypoint has it enabled.
  37. matrix_playbook_public_matrix_federation_api_traefik_entrypoint_config_http3_enabled: "{{ traefik_config_entrypoint_web_secure_http3_enabled }}"
  38. # `traefik_config_entrypoint_web_secure_enabled` is the variable we currently follow to determine if SSL is enabled or not.
  39. # `matrix_playbook_ssl_enabled` is merely an indicator if (when looked at it publicly), the server supports SSL or not,
  40. # and affects how services configure their public URLs.
  41. matrix_federation_traefik_entrypoint_tls: "{{ traefik_config_entrypoint_web_secure_enabled }}"
  42. ########################################################################
  43. # #
  44. # /Playbook #
  45. # #
  46. ########################################################################
  47. ########################################################################
  48. # #
  49. # aux #
  50. # #
  51. ########################################################################
  52. aux_directory_default_owner: "{{ matrix_user_username }}"
  53. aux_directory_default_group: "{{ matrix_user_groupname }}"
  54. aux_file_default_owner: "{{ matrix_user_username }}"
  55. aux_file_default_group: "{{ matrix_user_groupname }}"
  56. ########################################################################
  57. # #
  58. # /aux #
  59. # #
  60. ########################################################################
  61. ########################################################################
  62. # #
  63. # base #
  64. # #
  65. ########################################################################
  66. matrix_homeserver_container_extra_arguments_auto: |
  67. {{
  68. (['--mount type=bind,src=' + matrix_appservice_discord_config_path + '/registration.yaml,dst=/matrix-appservice-discord-registration.yaml,ro'] if matrix_appservice_discord_enabled else [])
  69. +
  70. (['--mount type=bind,src=' + matrix_appservice_draupnir_for_all_config_path + '/draupnir-for-all-registration.yaml,dst=/matrix-appservice-draupnir-for-all-registration.yaml,ro'] if matrix_appservice_draupnir_for_all_enabled else [])
  71. +
  72. (['--mount type=bind,src=' + matrix_appservice_double_puppet_config_path + '/registration.yaml,dst=/matrix-appservice-double-puppet-registration.yaml,ro'] if matrix_appservice_double_puppet_enabled else [])
  73. +
  74. (['--mount type=bind,src=' + matrix_appservice_irc_config_path + '/registration.yaml,dst=/matrix-appservice-irc-registration.yaml,ro'] if matrix_appservice_irc_enabled else [])
  75. +
  76. (['--mount type=bind,src=' + matrix_appservice_kakaotalk_config_path + '/registration.yaml,dst=/matrix-appservice-kakaotalk-registration.yaml,ro'] if matrix_appservice_kakaotalk_enabled else [])
  77. +
  78. (['--mount type=bind,src=' + matrix_appservice_slack_config_path + '/slack-registration.yaml,dst=/matrix-appservice-slack-registration.yaml,ro'] if matrix_appservice_slack_enabled else [])
  79. +
  80. (['--mount type=bind,src=' + matrix_appservice_webhooks_config_path + '/webhooks-registration.yaml,dst=/matrix-appservice-webhooks-registration.yaml,ro'] if matrix_appservice_webhooks_enabled else [])
  81. +
  82. (['--mount type=bind,src=' + matrix_beeper_linkedin_config_path + '/registration.yaml,dst=/matrix-beeper-linkedin-registration.yaml,ro'] if matrix_beeper_linkedin_enabled else [])
  83. +
  84. (['--mount type=bind,src=' + matrix_go_skype_bridge_config_path + '/registration.yaml,dst=/matrix-go-skype-bridge-registration.yaml,ro'] if matrix_go_skype_bridge_enabled else [])
  85. +
  86. (['--mount type=bind,src=' + matrix_wechat_config_path + '/registration.yaml,dst=/matrix-wechat-registration.yaml,ro'] if matrix_wechat_enabled else [])
  87. +
  88. (['--mount type=bind,src=' + matrix_heisenbridge_base_path + '/registration.yaml,dst=/heisenbridge-registration.yaml,ro'] if matrix_heisenbridge_enabled else [])
  89. +
  90. (['--mount type=bind,src=' + matrix_hookshot_base_path + '/registration.yml,dst=/hookshot-registration.yml,ro'] if matrix_hookshot_enabled else [])
  91. +
  92. (['--mount type=bind,src=' + matrix_mautrix_discord_config_path + '/registration.yaml,dst=/matrix-mautrix-discord-registration.yaml,ro'] if matrix_mautrix_discord_enabled else [])
  93. +
  94. (['--mount type=bind,src=' + matrix_mautrix_slack_config_path + '/registration.yaml,dst=/matrix-mautrix-slack-registration.yaml,ro'] if matrix_mautrix_slack_enabled else [])
  95. +
  96. (['--mount type=bind,src=' + matrix_mautrix_facebook_config_path + '/registration.yaml,dst=/matrix-mautrix-facebook-registration.yaml,ro'] if matrix_mautrix_facebook_enabled else [])
  97. +
  98. (['--mount type=bind,src=' + matrix_mautrix_googlechat_config_path + '/registration.yaml,dst=/matrix-mautrix-googlechat-registration.yaml,ro'] if matrix_mautrix_googlechat_enabled else [])
  99. +
  100. (['--mount type=bind,src=' + matrix_mautrix_hangouts_config_path + '/registration.yaml,dst=/matrix-mautrix-hangouts-registration.yaml,ro'] if matrix_mautrix_hangouts_enabled else [])
  101. +
  102. (['--mount type=bind,src=' + matrix_mautrix_instagram_config_path + '/registration.yaml,dst=/matrix-mautrix-instagram-registration.yaml,ro'] if matrix_mautrix_instagram_enabled else [])
  103. +
  104. (['--mount type=bind,src=' + matrix_mautrix_signal_config_path + '/registration.yaml,dst=/matrix-mautrix-signal-registration.yaml,ro'] if matrix_mautrix_signal_enabled else [])
  105. +
  106. (['--mount type=bind,src=' + matrix_mautrix_meta_messenger_config_path + '/registration.yaml,dst=/matrix-mautrix-meta-messenger-registration.yaml,ro'] if matrix_mautrix_meta_messenger_enabled else [])
  107. +
  108. (['--mount type=bind,src=' + matrix_mautrix_meta_instagram_config_path + '/registration.yaml,dst=/matrix-mautrix-meta-instagram-registration.yaml,ro'] if matrix_mautrix_meta_instagram_enabled else [])
  109. +
  110. (['--mount type=bind,src=' + matrix_mautrix_telegram_config_path + '/registration.yaml,dst=/matrix-mautrix-telegram-registration.yaml,ro'] if matrix_mautrix_telegram_enabled else [])
  111. +
  112. (['--mount type=bind,src=' + matrix_mautrix_twitter_config_path + '/registration.yaml,dst=/matrix-mautrix-twitter-registration.yaml,ro'] if matrix_mautrix_twitter_enabled else [])
  113. +
  114. (['--mount type=bind,src=' + matrix_mautrix_gmessages_config_path + '/registration.yaml,dst=/matrix-mautrix-gmessages-registration.yaml,ro'] if matrix_mautrix_gmessages_enabled else [])
  115. +
  116. (['--mount type=bind,src=' + matrix_mautrix_whatsapp_config_path + '/registration.yaml,dst=/matrix-mautrix-whatsapp-registration.yaml,ro'] if matrix_mautrix_whatsapp_enabled else [])
  117. +
  118. (['--mount type=bind,src=' + matrix_mautrix_wsproxy_config_path + '/androidsms-registration.yaml,dst=/matrix-mautrix-androidsms-registration.yaml,ro'] if matrix_mautrix_wsproxy_enabled else [])
  119. +
  120. (['--mount type=bind,src=' + matrix_mautrix_wsproxy_config_path + '/imessage-registration.yaml,dst=/matrix-mautrix-imessage-registration.yaml,ro'] if matrix_mautrix_wsproxy_enabled else [])
  121. +
  122. (['--mount type=bind,src=' + matrix_mx_puppet_discord_config_path + '/registration.yaml,dst=/matrix-mx-puppet-discord-registration.yaml,ro'] if matrix_mx_puppet_discord_enabled else [])
  123. +
  124. (['--mount type=bind,src=' + matrix_mx_puppet_groupme_config_path + '/registration.yaml,dst=/matrix-mx-puppet-groupme-registration.yaml,ro'] if matrix_mx_puppet_groupme_enabled else [])
  125. +
  126. (['--mount type=bind,src=' + matrix_mx_puppet_instagram_config_path + '/registration.yaml,dst=/matrix-mx-puppet-instagram-registration.yaml,ro'] if matrix_mx_puppet_instagram_enabled else [])
  127. +
  128. (['--mount type=bind,src=' + matrix_mx_puppet_slack_config_path + '/registration.yaml,dst=/matrix-mx-puppet-slack-registration.yaml,ro'] if matrix_mx_puppet_slack_enabled else [])
  129. +
  130. (['--mount type=bind,src=' + matrix_mx_puppet_steam_config_path + '/registration.yaml,dst=/matrix-mx-puppet-steam-registration.yaml,ro'] if matrix_mx_puppet_steam_enabled else [])
  131. +
  132. (['--mount type=bind,src=' + matrix_mx_puppet_twitter_config_path + '/registration.yaml,dst=/matrix-mx-puppet-twitter-registration.yaml,ro'] if matrix_mx_puppet_twitter_enabled else [])
  133. +
  134. (['--mount type=bind,src=' + matrix_sms_bridge_config_path + '/registration.yaml,dst=/matrix-sms-bridge-registration.yaml,ro'] if matrix_sms_bridge_enabled else [])
  135. +
  136. (['--mount type=bind,src=' + matrix_cactus_comments_app_service_config_file + ',dst=/matrix-cactus-comments.yaml,ro'] if matrix_cactus_comments_enabled else [])
  137. }}
  138. matrix_homeserver_app_service_config_files_auto: |
  139. {{
  140. (['/matrix-appservice-discord-registration.yaml'] if matrix_appservice_discord_enabled else [])
  141. +
  142. (['/matrix-appservice-draupnir-for-all-registration.yaml'] if matrix_appservice_draupnir_for_all_enabled else [])
  143. +
  144. (['/matrix-appservice-double-puppet-registration.yaml'] if matrix_appservice_double_puppet_enabled else [])
  145. +
  146. (['/matrix-appservice-irc-registration.yaml'] if matrix_appservice_irc_enabled else [])
  147. +
  148. (['/matrix-appservice-kakaotalk-registration.yaml'] if matrix_appservice_kakaotalk_enabled else [])
  149. +
  150. (['/matrix-appservice-slack-registration.yaml'] if matrix_appservice_slack_enabled else [])
  151. +
  152. (['/matrix-appservice-webhooks-registration.yaml'] if matrix_appservice_webhooks_enabled else [])
  153. +
  154. (['/matrix-beeper-linkedin-registration.yaml'] if matrix_beeper_linkedin_enabled else [])
  155. +
  156. (['/matrix-go-skype-bridge-registration.yaml'] if matrix_go_skype_bridge_enabled else [])
  157. +
  158. (['/matrix-wechat-registration.yaml'] if matrix_wechat_enabled else [])
  159. +
  160. (['/heisenbridge-registration.yaml'] if matrix_heisenbridge_enabled else [])
  161. +
  162. (['/hookshot-registration.yml'] if matrix_hookshot_enabled else [])
  163. +
  164. (['/matrix-mautrix-discord-registration.yaml'] if matrix_mautrix_discord_enabled else [])
  165. +
  166. (['/matrix-mautrix-slack-registration.yaml'] if matrix_mautrix_slack_enabled else [])
  167. +
  168. (['/matrix-mautrix-facebook-registration.yaml'] if matrix_mautrix_facebook_enabled else [])
  169. +
  170. (['/matrix-mautrix-googlechat-registration.yaml'] if matrix_mautrix_googlechat_enabled else [])
  171. +
  172. (['/matrix-mautrix-hangouts-registration.yaml'] if matrix_mautrix_hangouts_enabled else [])
  173. +
  174. (['/matrix-mautrix-instagram-registration.yaml'] if matrix_mautrix_instagram_enabled else [])
  175. +
  176. (['/matrix-mautrix-signal-registration.yaml'] if matrix_mautrix_signal_enabled else [])
  177. +
  178. (['/matrix-mautrix-meta-messenger-registration.yaml'] if matrix_mautrix_meta_messenger_enabled else [])
  179. +
  180. (['/matrix-mautrix-meta-instagram-registration.yaml'] if matrix_mautrix_meta_instagram_enabled else [])
  181. +
  182. (['/matrix-mautrix-telegram-registration.yaml'] if matrix_mautrix_telegram_enabled else [])
  183. +
  184. (['/matrix-mautrix-twitter-registration.yaml'] if matrix_mautrix_twitter_enabled else [])
  185. +
  186. (['/matrix-mautrix-gmessages-registration.yaml'] if matrix_mautrix_gmessages_enabled else [])
  187. +
  188. (['/matrix-mautrix-whatsapp-registration.yaml'] if matrix_mautrix_whatsapp_enabled else [])
  189. +
  190. (['/matrix-mautrix-androidsms-registration.yaml'] if matrix_mautrix_wsproxy_enabled else [])
  191. +
  192. (['/matrix-mautrix-imessage-registration.yaml'] if matrix_mautrix_wsproxy_enabled else [])
  193. +
  194. (['/matrix-mx-puppet-discord-registration.yaml'] if matrix_mx_puppet_discord_enabled else [])
  195. +
  196. (['/matrix-mx-puppet-groupme-registration.yaml'] if matrix_mx_puppet_groupme_enabled else [])
  197. +
  198. (['/matrix-mx-puppet-instagram-registration.yaml'] if matrix_mx_puppet_instagram_enabled else [])
  199. +
  200. (['/matrix-mx-puppet-slack-registration.yaml'] if matrix_mx_puppet_slack_enabled else [])
  201. +
  202. (['/matrix-mx-puppet-steam-registration.yaml'] if matrix_mx_puppet_steam_enabled else [])
  203. +
  204. (['/matrix-mx-puppet-twitter-registration.yaml'] if matrix_mx_puppet_twitter_enabled else [])
  205. +
  206. (['/matrix-sms-bridge-registration.yaml'] if matrix_sms_bridge_enabled else [])
  207. +
  208. (['/matrix-cactus-comments.yaml'] if matrix_cactus_comments_enabled else [])
  209. }}
  210. matrix_addons_homeserver_container_network: "{{ matrix_playbook_reverse_proxy_container_network if matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled else matrix_homeserver_container_network }}"
  211. matrix_addons_homeserver_client_api_url: "{{ ('http://' + matrix_playbook_reverse_proxy_hostname + ':' + matrix_playbook_internal_matrix_client_api_traefik_entrypoint_port | string) if matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled else matrix_homeserver_container_url }}"
  212. matrix_addons_homeserver_systemd_services_list: "{{ ([traefik_identifier + '.service'] if matrix_playbook_reverse_proxy_type == 'playbook-managed-traefik' else []) if matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled else matrix_homeserver_systemd_services_list }}"
  213. # Starting from version `0.6.0` Conduit natively supports some sync v3 (sliding-sync) features.
  214. matrix_homeserver_sliding_sync_url: "{{ matrix_sliding_sync_base_url if matrix_sliding_sync_enabled else (matrix_homeserver_url if matrix_homeserver_implementation in ['conduit'] else '') }}"
  215. ########################################################################
  216. # #
  217. # /base #
  218. # #
  219. ########################################################################
  220. ########################################################################
  221. # #
  222. # com.devture.ansible.role.systemd_service_manager #
  223. # #
  224. ########################################################################
  225. # This list is not exhaustive and final.
  226. # Synapse workers are still injected into the list at runtime.
  227. # Additional JVB workers (jitsi_jvb.yml -- roles/galaxy/jitsi/tasks/init_additional_jvb.yml) override this variable at runtime as well.
  228. #
  229. # Priority levels are like this:
  230. # - Traefik starts first with a level of 250, so that:
  231. # - it can get an early start on obtaining SSL certificates and routing to other services as soon as they start (later)
  232. # - so that addon services (starting later) can communicte with the homeserver via Traefik's internal entrypoint
  233. # (see `matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled`)
  234. # - core services (the homeserver) get a level of ~1000
  235. # - services that the homeserver depends on (database, Redis, ntfy, Coturn, etc.) get a lower level - between 500 and 1000
  236. # - Coturn gets a higher level if `devture_systemd_service_manager_service_restart_mode == 'one-by-one'` to intentionally delay it, because:
  237. # - starting services one by one means that the service manager role waits for each service to fully start before proceeding to the next one
  238. # - if Coturn has a lower priority than the homeserver, it would be started before it
  239. # - since Coturn is started before the homeserver, there's no container label telling Traefik to get a `matrix.example.com` certificate
  240. # - thus, Coturn would spin and wait for a certificate until it fails. We'd get a playbook failure due to it, but service manager will proceed to start all other services anyway.
  241. # - only later, when the homeserver actually starts, would that certificate be fetched and dumped
  242. # - reverse-proxying services get level 3000
  243. # - Matrix utility services (bridges, bots) get a level of 2000/2200, so that:
  244. # - they can start before the reverse-proxy
  245. # - so that, when the reverse-proxy is up (Matrix is up), all bots and bridges can be interacted with
  246. # - monitoring services (Prometheus, Grafana, ..) get a level of 4000 - they can start later than all-of-Matrix
  247. # - services which aren't time-sensitive (various crons and timers) get a level of 5000 - they can start later than all-of-Matrix
  248. devture_systemd_service_manager_services_list_auto: |
  249. {{
  250. ([{'name': (backup_borg_identifier + '.timer'), 'priority': 5000, 'groups': ['matrix', 'backup', 'borg']}] if backup_borg_enabled else [])
  251. +
  252. ([{'name': 'matrix-alertmanager-receiver.service', 'priority': 2200, 'groups': ['matrix', 'alertmanager-receiver']}] if matrix_alertmanager_receiver_enabled else [])
  253. +
  254. ([{'name': 'matrix-authentication-service.service', 'priority': 2200, 'groups': ['matrix', 'matrix-authentication-service']}] if matrix_authentication_service_enabled else [])
  255. +
  256. ([{'name': 'matrix-bot-buscarron.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'buscarron', 'bot-buscarron']}] if matrix_bot_buscarron_enabled else [])
  257. +
  258. ([{'name': 'matrix-bot-baibot.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'baibot', 'bot-baibot']}] if matrix_bot_baibot_enabled else [])
  259. +
  260. ([{'name': 'matrix-bot-go-neb.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'go-neb', 'bot-go-neb']}] if matrix_bot_go_neb_enabled else [])
  261. +
  262. ([{'name': 'matrix-bot-honoroit.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'honoroit', 'bot-honoroit']}] if matrix_bot_honoroit_enabled else [])
  263. +
  264. ([{'name': 'matrix-bot-matrix-registration-bot.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'registration-bot', 'bot-matrix-registration-bot']}] if matrix_bot_matrix_registration_bot_enabled else [])
  265. +
  266. ([{'name': 'matrix-bot-matrix-reminder-bot.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'reminder-bot', 'bot-matrix-reminder-bot']}] if matrix_bot_matrix_reminder_bot_enabled else [])
  267. +
  268. ([{'name': 'matrix-bot-maubot.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'maubot', 'bot-maubot']}] if matrix_bot_maubot_enabled else [])
  269. +
  270. ([{'name': 'matrix-bot-mjolnir.service', 'priority': 4000, 'groups': ['matrix', 'bots', 'mjolnir', 'bot-mjolnir']}] if matrix_bot_mjolnir_enabled else [])
  271. +
  272. ([{'name': 'matrix-bot-draupnir.service', 'priority': 4000, 'groups': ['matrix', 'bots', 'draupnir', 'bot-draupnir']}] if matrix_bot_draupnir_enabled else [])
  273. +
  274. ([{'name': 'matrix-bot-chatgpt.service', 'priority': 2200, 'groups': ['matrix', 'bots', 'chatgpt', 'bot-chatgpt']}] if matrix_bot_chatgpt_enabled else [])
  275. +
  276. ([{'name': 'matrix-appservice-discord.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'appservice-discord']}] if matrix_appservice_discord_enabled else [])
  277. +
  278. ([{'name': 'matrix-appservice-draupnir-for-all.service', 'priority': 4000, 'groups': ['matrix', 'bridges', 'draupnir-for-all', 'appservice-draupnir-for-all']}] if matrix_appservice_draupnir_for_all_enabled else [])
  279. +
  280. ([{'name': 'matrix-appservice-irc.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'appservice-irc']}] if matrix_appservice_irc_enabled else [])
  281. +
  282. ([{'name': 'matrix-appservice-kakaotalk.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'appservice-kakaotalk']}] if matrix_appservice_kakaotalk_enabled else [])
  283. +
  284. ([{'name': 'matrix-appservice-kakaotalk-node.service', 'priority': 1900, 'groups': ['matrix', 'bridges', 'appservice-kakaotalk', 'appservice-kakaotalk-node']}] if matrix_appservice_kakaotalk_enabled else [])
  285. +
  286. ([{'name': 'matrix-appservice-slack.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'appservice-slack']}] if matrix_appservice_slack_enabled else [])
  287. +
  288. ([{'name': 'matrix-appservice-webhooks.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'appservice-webhooks']}] if matrix_appservice_webhooks_enabled else [])
  289. +
  290. ([{'name': 'matrix-beeper-linkedin.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'beeper-linkedin']}] if matrix_beeper_linkedin_enabled else [])
  291. +
  292. ([{'name': 'matrix-go-skype-bridge.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'go-skype']}] if matrix_go_skype_bridge_enabled else [])
  293. +
  294. ([{'name': 'matrix-wechat.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'wechat']}] if matrix_wechat_enabled else [])
  295. +
  296. ([{'name': 'matrix-wechat-agent.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'wechat']}] if matrix_wechat_enabled else [])
  297. +
  298. ([{'name': 'matrix-heisenbridge.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'heisenbridge']}] if matrix_heisenbridge_enabled else [])
  299. +
  300. ([{'name': 'matrix-hookshot.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'hookshot', 'bridge-hookshot']}] if matrix_hookshot_enabled else [])
  301. +
  302. ([{'name': 'matrix-mautrix-discord.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-discord']}] if matrix_mautrix_discord_enabled else [])
  303. +
  304. ([{'name': 'matrix-mautrix-slack.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-slack']}] if matrix_mautrix_slack_enabled else [])
  305. +
  306. ([{'name': 'matrix-mautrix-facebook.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-facebook']}] if matrix_mautrix_facebook_enabled else [])
  307. +
  308. ([{'name': 'matrix-mautrix-googlechat.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-googlechat']}] if matrix_mautrix_googlechat_enabled else [])
  309. +
  310. ([{'name': 'matrix-mautrix-hangouts.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-hangouts']}] if matrix_mautrix_hangouts_enabled else [])
  311. +
  312. ([{'name': 'matrix-mautrix-instagram.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-instagram']}] if matrix_mautrix_instagram_enabled else [])
  313. +
  314. ([{'name': 'matrix-mautrix-signal.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-signal', 'mautrix-signal']}] if matrix_mautrix_signal_enabled else [])
  315. +
  316. ([{'name': (matrix_mautrix_meta_messenger_identifier + '.service'), 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-meta', 'mautrix-meta-messenger']}] if matrix_mautrix_meta_messenger_enabled else [])
  317. +
  318. ([{'name': (matrix_mautrix_meta_instagram_identifier + '.service'), 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-meta', 'mautrix-meta-instagram']}] if matrix_mautrix_meta_instagram_enabled else [])
  319. +
  320. ([{'name': 'matrix-mautrix-telegram.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-telegram']}] if matrix_mautrix_telegram_enabled else [])
  321. +
  322. ([{'name': 'matrix-mautrix-twitter.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-twitter']}] if matrix_mautrix_twitter_enabled else [])
  323. +
  324. ([{'name': 'matrix-mautrix-gmessages.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-gmessages']}] if matrix_mautrix_gmessages_enabled else [])
  325. +
  326. ([{'name': 'matrix-mautrix-whatsapp.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-whatsapp']}] if matrix_mautrix_whatsapp_enabled else [])
  327. +
  328. ([{'name': 'matrix-mautrix-wsproxy.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-wsproxy']}] if matrix_mautrix_wsproxy_enabled else [])
  329. +
  330. ([{'name': 'matrix-mautrix-wsproxy-syncproxy.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mautrix-wsproxy-syncproxy']}] if matrix_mautrix_wsproxy_enabled else [])
  331. +
  332. ([{'name': 'matrix-mx-puppet-discord.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mx-puppet-discord']}] if matrix_mx_puppet_discord_enabled else [])
  333. +
  334. ([{'name': 'matrix-mx-puppet-groupme.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mx-puppet-groupme']}] if matrix_mx_puppet_groupme_enabled else [])
  335. +
  336. ([{'name': 'matrix-mx-puppet-instagram.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mx-puppet-instagram']}] if matrix_mx_puppet_instagram_enabled else [])
  337. +
  338. ([{'name': 'matrix-mx-puppet-slack.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mx-puppet-slack']}] if matrix_mx_puppet_slack_enabled else [])
  339. +
  340. ([{'name': 'matrix-mx-puppet-steam.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mx-puppet-steam']}] if matrix_mx_puppet_steam_enabled else [])
  341. +
  342. ([{'name': 'matrix-mx-puppet-twitter.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'mx-puppet-twitter']}] if matrix_mx_puppet_twitter_enabled else [])
  343. +
  344. ([{'name': 'matrix-postmoogle.service', 'priority': 2200, 'groups': ['matrix', 'bridges', 'postmoogle']}] if matrix_postmoogle_enabled else [])
  345. +
  346. ([{'name': 'matrix-sms-bridge.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'sms']}] if matrix_sms_bridge_enabled else [])
  347. +
  348. ([{'name': 'matrix-cactus-comments.service', 'priority': 2000, 'groups': ['matrix', 'cactus-comments']}] if matrix_cactus_comments_enabled else [])
  349. +
  350. ([{'name': 'matrix-cactus-comments-client.service', 'priority': 2000, 'groups': ['matrix', 'cactus-comments-client']}] if matrix_cactus_comments_client_enabled else [])
  351. +
  352. ([{'name': 'matrix-client-cinny.service', 'priority': 2000, 'groups': ['matrix', 'clients', 'cinny', 'client-cinny']}] if matrix_client_cinny_enabled else [])
  353. +
  354. ([{'name': 'matrix-client-element.service', 'priority': 2000, 'groups': ['matrix', 'clients', 'element', 'client-element']}] if matrix_client_element_enabled else [])
  355. +
  356. ([{'name': 'matrix-client-hydrogen.service', 'priority': 2000, 'groups': ['matrix', 'clients', 'hydrogen', 'client-hydrogen']}] if matrix_client_hydrogen_enabled else [])
  357. +
  358. ([{'name': 'matrix-client-schildichat.service', 'priority': 2000, 'groups': ['matrix', 'clients', 'schildichat', 'client-schildichat']}] if matrix_client_schildichat_enabled else [])
  359. +
  360. ([{'name': ('matrix-' + matrix_homeserver_implementation + '.service'), 'priority': 1000, 'groups': ['matrix', 'homeservers', matrix_homeserver_implementation]}] if matrix_homeserver_enabled else [])
  361. +
  362. ([{'name': 'matrix-corporal.service', 'priority': 1500, 'groups': ['matrix', 'corporal']}] if matrix_corporal_enabled else [])
  363. +
  364. ([{'name': 'matrix-coturn.service', 'priority': (900 if devture_systemd_service_manager_service_restart_mode == 'clean-stop-start' else 1500), 'groups': ['matrix', 'coturn']}] if matrix_coturn_enabled else [])
  365. +
  366. ([{'name': 'matrix-rageshake.service', 'priority': 4000, 'groups': ['matrix', 'rageshake']}] if matrix_rageshake_enabled else [])
  367. +
  368. ([{'name': 'matrix-coturn-reload.timer', 'priority': 5000, 'groups': ['matrix', 'coturn']}] if (matrix_coturn_enabled and matrix_coturn_tls_enabled) else [])
  369. +
  370. ([{'name': 'matrix-dimension.service', 'priority': 4000, 'groups': ['matrix', 'integration-managers', 'dimension']}] if matrix_dimension_enabled else [])
  371. +
  372. ([{'name': 'matrix-dynamic-dns.service', 'priority': 5000, 'groups': ['matrix', 'dynamic-dns']}] if matrix_dynamic_dns_enabled else [])
  373. +
  374. ([{'name': 'matrix-email2matrix.service', 'priority': 2000, 'groups': ['matrix', 'bridges', 'email2matrix']}] if matrix_email2matrix_enabled else [])
  375. +
  376. ([{'name': (etherpad_identifier + '.service'), 'priority': 4000, 'groups': ['matrix', 'etherpad']}] if etherpad_enabled else [])
  377. +
  378. ([{'name': (grafana_identifier + '.service'), 'priority': 4000, 'groups': ['matrix', 'monitoring', 'grafana']}] if grafana_enabled else [])
  379. +
  380. ([{'name': (jitsi_identifier + '-web.service'), 'priority': 4200, 'groups': ['matrix', 'jitsi', 'jitsi-web']}] if jitsi_enabled else [])
  381. +
  382. ([{'name': (jitsi_identifier + '-prosody.service'), 'priority': 4000, 'groups': ['matrix', 'jitsi', 'jitsi-prosody']}] if jitsi_enabled else [])
  383. +
  384. ([{'name': (jitsi_identifier + '-jicofo.service'), 'priority': 4100, 'groups': ['matrix', 'jitsi', 'jitsi-jicofo']}] if jitsi_enabled else [])
  385. +
  386. ([{'name': (jitsi_identifier + '-jvb.service'), 'priority': 4100, 'groups': ['matrix', 'jitsi', 'jitsi-jvb']}] if jitsi_enabled else [])
  387. +
  388. ([{'name': 'matrix-ldap-registration-proxy.service', 'priority': 2000, 'groups': ['matrix', 'ldap-registration-proxy']}] if matrix_ldap_registration_proxy_enabled else [])
  389. +
  390. ([{'name': 'matrix-ma1sd.service', 'priority': 2000, 'groups': ['matrix', 'ma1sd']}] if matrix_ma1sd_enabled else [])
  391. +
  392. ([{'name': (matrix_media_repo_identifier + '.service'), 'priority': 4000, 'groups': ['matrix', 'matrix-media-repo']}] if matrix_media_repo_enabled else [])
  393. +
  394. ([{'name': (exim_relay_identifier ~ '.service'), 'priority': 800, 'groups': ['matrix', 'mailer', 'exim-relay']}] if exim_relay_enabled else [])
  395. +
  396. ([{'name': (ntfy_identifier + '.service'), 'priority': 800, 'groups': ['matrix', 'ntfy']}] if ntfy_enabled else [])
  397. +
  398. ([{'name': (postgres_identifier + '.service'), 'priority': 500, 'groups': ['matrix', 'postgres']}] if postgres_enabled else [])
  399. +
  400. ([{'name': (postgres_backup_identifier + '.service'), 'priority': 5000, 'groups': ['matrix', 'backup', 'postgres-backup']}] if postgres_backup_enabled else [])
  401. +
  402. ([{'name': (prometheus_identifier + '.service'), 'priority': 4000, 'groups': ['matrix', 'monitoring', 'prometheus']}] if prometheus_enabled else [])
  403. +
  404. ([{'name': (prometheus_node_exporter_identifier + '.service'), 'priority': 3900, 'groups': ['matrix', 'monitoring', 'prometheus-exporters', 'prometheus-node-exporter']}] if prometheus_node_exporter_enabled else [])
  405. +
  406. ([{'name': (prometheus_postgres_exporter_identifier + '.service'), 'priority': 3900, 'groups': ['matrix', 'monitoring', 'prometheus-exporters', 'prometheus-postgres-exporter']}] if prometheus_postgres_exporter_enabled else [])
  407. +
  408. ([{'name': 'matrix-prometheus-nginxlog-exporter.service', 'priority': 3900, 'groups': ['matrix', 'monitoring', 'prometheus-exporters', 'prometheus-nginxlog-exporter']}] if matrix_prometheus_nginxlog_exporter_enabled else [])
  409. +
  410. ([{'name': (redis_identifier + '.service'), 'priority': 750, 'groups': ['matrix', 'redis']}] if redis_enabled else [])
  411. +
  412. ([{'name': (keydb_identifier + '.service'), 'priority': 750, 'groups': ['matrix', 'keydb']}] if keydb_enabled else [])
  413. +
  414. ([{'name': (valkey_identifier + '.service'), 'priority': 750, 'groups': ['matrix', 'valkey']}] if valkey_enabled else [])
  415. +
  416. ([{'name': 'matrix-pantalaimon.service', 'priority': 4000, 'groups': ['matrix', 'pantalaimon']}] if matrix_pantalaimon_enabled else [])
  417. +
  418. ([{'name': 'matrix-registration.service', 'priority': 4000, 'groups': ['matrix', 'registration', 'matrix-registration']}] if matrix_registration_enabled else [])
  419. +
  420. ([{'name': 'matrix-sliding-sync.service', 'priority': 1500, 'groups': ['matrix', 'sliding-sync']}] if matrix_sliding_sync_enabled else [])
  421. +
  422. ([{'name': 'matrix-sygnal.service', 'priority': 800, 'groups': ['matrix', 'sygnal']}] if matrix_sygnal_enabled else [])
  423. +
  424. ([{'name': 'matrix-goofys.service', 'priority': 800, 'groups': ['matrix', 'goofys']}] if matrix_s3_media_store_enabled else [])
  425. +
  426. ([{'name': 'matrix-synapse-s3-storage-provider-migrate.timer', 'priority': 5000, 'groups': ['matrix']}] if matrix_synapse_ext_synapse_s3_storage_provider_enabled else [])
  427. +
  428. ([{'name': 'matrix-synapse-auto-compressor.timer', 'priority': 5000, 'groups': ['matrix', 'synapse-auto-compressor']}] if matrix_synapse_auto_compressor_enabled else [])
  429. +
  430. ([{'name': 'matrix-synapse-admin.service', 'priority': 4000, 'groups': ['matrix', 'synapse-admin']}] if matrix_synapse_admin_enabled else [])
  431. +
  432. ([{'name': (matrix_synapse_usage_exporter_identifier + '.service'), 'priority': 4000, 'groups': ['matrix', 'synapse-usage-exporter']}] if matrix_synapse_usage_exporter_enabled else [])
  433. +
  434. ([{'name': 'matrix-synapse-reverse-proxy-companion.service', 'priority': 1500, 'groups': ['matrix', 'homeservers', 'synapse', 'synapse-reverse-proxy-companion', 'reverse-proxies']}] if matrix_synapse_reverse_proxy_companion_enabled else [])
  435. +
  436. ([{'name': 'matrix-user-verification-service.service', 'priority': 800, 'groups': ['matrix', 'matrix-user-verification-service']}] if matrix_user_verification_service_enabled else [])
  437. +
  438. ([{'name': (matrix_static_files_identifier + '.service'), 'priority': 4000, 'groups': ['matrix', 'matrix-static-files']}] if matrix_static_files_enabled else [])
  439. +
  440. ([{'name': (devture_container_socket_proxy_identifier + '.service'), 'priority': 200, 'groups': ['matrix', 'reverse-proxies', 'container-socket-proxy']}] if devture_container_socket_proxy_enabled else [])
  441. +
  442. ([{'name': (traefik_identifier + '.service'), 'priority': 250, 'groups': ['matrix', 'traefik', 'reverse-proxies']}] if traefik_enabled else [])
  443. +
  444. ([{'name': (traefik_certs_dumper_identifier + '.service'), 'priority': 300, 'groups': ['matrix', 'traefik-certs-dumper']}] if traefik_certs_dumper_enabled else [])
  445. }}
  446. ########################################################################
  447. # #
  448. # /com.devture.ansible.role.systemd_service_manager #
  449. # #
  450. ########################################################################
  451. ########################################################################
  452. # #
  453. # com.devture.ansible.role.timesync #
  454. # #
  455. ########################################################################
  456. # To completely disable installing systemd-timesyncd/ntpd, use `devture_timesync_installation_enabled: false`.
  457. ########################################################################
  458. # #
  459. # /com.devture.ansible.role.timesync #
  460. # #
  461. ########################################################################
  462. ######################################################################
  463. #
  464. # com.devture.ansible.role.playbook_state_preserver
  465. #
  466. ######################################################################
  467. # To completely disable this feature, use `devture_playbook_state_preserver_enabled: false`.
  468. devture_playbook_state_preserver_uid: "{{ matrix_user_uid }}"
  469. devture_playbook_state_preserver_gid: "{{ matrix_user_gid }}"
  470. devture_playbook_state_preserver_vars_preservation_dst: "{{ matrix_base_data_path }}/vars.yml"
  471. devture_playbook_state_preserver_commit_hash_preservation_dst: "{{ matrix_base_data_path }}/git_hash.yml"
  472. ######################################################################
  473. #
  474. # /com.devture.ansible.role.playbook_state_preserver
  475. #
  476. ######################################################################
  477. ########################################################################
  478. # #
  479. # geerlingguy/ansible-role-docker #
  480. # #
  481. ########################################################################
  482. docker_daemon_options: "{{ matrix_playbook_docker_installation_daemon_options }}"
  483. ########################################################################
  484. # #
  485. # /geerlingguy/ansible-role-docker #
  486. # #
  487. ########################################################################
  488. ######################################################################
  489. #
  490. # matrix-base
  491. #
  492. ######################################################################
  493. matrix_identity_server_url: "{{ (('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_matrix) if matrix_ma1sd_enabled else None }}"
  494. matrix_homeserver_systemd_services_list: |-
  495. {{
  496. (
  497. ([('matrix-' + matrix_homeserver_implementation + '.service')] if matrix_homeserver_implementation != 'synapse' else [])
  498. +
  499. ([('matrix-' + matrix_homeserver_implementation + '.service')] if matrix_homeserver_implementation == 'synapse' and not matrix_synapse_reverse_proxy_companion_enabled else [])
  500. +
  501. (['matrix-synapse-reverse-proxy-companion.service'] if matrix_synapse_reverse_proxy_companion_enabled else [])
  502. ) | unique
  503. }}
  504. matrix_homeserver_container_client_api_endpoint: |-
  505. {{
  506. {
  507. 'synapse': ('matrix-synapse-reverse-proxy-companion:8008' if matrix_synapse_reverse_proxy_companion_enabled | default(false) else ('matrix-synapse:'+ matrix_synapse_container_client_api_port | default('8008') | string)),
  508. 'dendrite': ('matrix-dendrite:' + matrix_dendrite_http_bind_port | default('8008') | string),
  509. 'conduit': ('matrix-conduit:' + matrix_conduit_port_number | default('8008') | string),
  510. }[matrix_homeserver_implementation]
  511. }}
  512. matrix_homeserver_container_federation_api_endpoint: |-
  513. {{
  514. {
  515. 'synapse': ('matrix-synapse-reverse-proxy-companion:8048' if matrix_synapse_reverse_proxy_companion_enabled else ('matrix-synapse:'+ matrix_synapse_container_federation_api_plain_port | default('8008') | string)),
  516. 'dendrite': ('matrix-dendrite:' + matrix_dendrite_http_bind_port | default('8008') | string),
  517. 'conduit': ('matrix-conduit:' + matrix_conduit_port_number | default('8008') | string),
  518. }[matrix_homeserver_implementation]
  519. }}
  520. matrix_integration_manager_rest_url: "{{ matrix_dimension_integrations_rest_url if matrix_dimension_enabled else None }}"
  521. matrix_integration_manager_ui_url: "{{ matrix_dimension_integrations_ui_url if matrix_dimension_enabled else None }}"
  522. ######################################################################
  523. #
  524. # /matrix-base
  525. #
  526. ######################################################################
  527. ######################################################################
  528. #
  529. # matrix-alertmanager-receiver
  530. #
  531. ######################################################################
  532. # We don't enable this by default.
  533. matrix_alertmanager_receiver_enabled: false
  534. matrix_alertmanager_receiver_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  535. matrix_alertmanager_receiver_container_network: "{{ matrix_addons_container_network }}"
  536. matrix_alertmanager_receiver_container_additional_networks_auto: |-
  537. {{
  538. (
  539. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  540. +
  541. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_alertmanager_receiver_container_labels_traefik_enabled) else [])
  542. ) | unique
  543. }}
  544. matrix_alertmanager_receiver_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  545. matrix_alertmanager_receiver_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  546. matrix_alertmanager_receiver_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  547. matrix_alertmanager_receiver_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  548. matrix_alertmanager_receiver_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  549. matrix_alertmanager_receiver_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  550. matrix_alertmanager_receiver_systemd_required_services_list_auto: "{{ matrix_addons_homeserver_systemd_services_list }}"
  551. matrix_alertmanager_receiver_config_matrix_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  552. matrix_alertmanager_receiver_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  553. matrix_alertmanager_receiver_metrics_proxying_enabled: "{{ matrix_alertmanager_receiver_config_http_metrics_enabled and matrix_metrics_exposure_enabled }}"
  554. matrix_alertmanager_receiver_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  555. matrix_alertmanager_receiver_metrics_proxying_path: "{{ matrix_metrics_exposure_path_prefix }}/matrix-alertmanager-receiver"
  556. ######################################################################
  557. #
  558. # /matrix-alertmanager-receiver
  559. #
  560. ######################################################################
  561. ######################################################################
  562. #
  563. # matrix-authentication-service
  564. #
  565. ######################################################################
  566. matrix_authentication_service_enabled: false
  567. matrix_authentication_service_hostname: "{{ matrix_server_fqn_matrix }}"
  568. matrix_authentication_service_path_prefix: /auth
  569. matrix_authentication_service_config_database_host: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  570. matrix_authentication_service_config_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mas.db', rounds=655555) | to_uuid }}"
  571. matrix_authentication_service_config_matrix_homeserver: "{{ matrix_domain }}"
  572. matrix_authentication_service_config_matrix_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mas.hs.secret', rounds=655555) | to_uuid }}"
  573. matrix_authentication_service_config_matrix_endpoint: "{{ matrix_homeserver_container_url }}"
  574. # We're using a non-default configuration which:
  575. # - allows passwords from Synapse (hashed with bcrypt) to be imported with scheme version 1 so existing users will be able to login
  576. # - as soon as they do one login, the hash will be 'upgraded' to argon2id
  577. matrix_authentication_service_config_passwords_schemes:
  578. - version: 1
  579. secret: "{{ matrix_synapse_password_config_pepper }}"
  580. algorithm: bcrypt
  581. - version: 2
  582. algorithm: argon2id
  583. matrix_authentication_service_config_clients_auto: |-
  584. {{
  585. ([
  586. {
  587. 'client_id': matrix_synapse_experimental_features_msc3861_client_id,
  588. 'client_auth_method': matrix_synapse_experimental_features_msc3861_client_auth_method,
  589. 'client_secret': matrix_synapse_experimental_features_msc3861_client_secret,
  590. }
  591. ] if matrix_synapse_experimental_features_msc3861_enabled else [])
  592. }}
  593. matrix_authentication_service_config_email_transport: "{{ 'smtp' if exim_relay_enabled else 'blackhole' }}"
  594. matrix_authentication_service_config_email_hostname: "{{ exim_relay_identifier if exim_relay_enabled else '' }}"
  595. matrix_authentication_service_config_email_port: "{{ 8025 if exim_relay_enabled else 587 }}"
  596. matrix_authentication_service_config_email_mode: "{{ 'plain' if exim_relay_enabled else 'starttls' }}"
  597. matrix_authentication_service_config_email_from_address: "{{ exim_relay_sender_address }}"
  598. matrix_authentication_service_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  599. matrix_authentication_service_container_network: "{{ matrix_homeserver_container_network }}"
  600. matrix_authentication_service_container_additional_networks_auto: |-
  601. {{
  602. (
  603. ([postgres_container_network] if postgres_enabled and matrix_authentication_service_config_database_host == postgres_connection_hostname else [])
  604. +
  605. ([exim_relay_container_network] if (exim_relay_enabled and matrix_authentication_service_config_email_transport == 'smtp' and matrix_authentication_service_config_email_hostname == exim_relay_identifier and matrix_authentication_service_container_network != exim_relay_container_network) else [])
  606. +
  607. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_authentication_service_container_labels_traefik_enabled else [])
  608. ) | unique
  609. }}
  610. matrix_authentication_service_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  611. matrix_authentication_service_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  612. matrix_authentication_service_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  613. matrix_authentication_service_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  614. matrix_authentication_service_container_labels_public_compatibility_layer_enabled: "{{ not matrix_authentication_service_migration_in_progress}}"
  615. matrix_authentication_service_container_labels_public_compatibility_layer_hostname: "{{ matrix_server_fqn_matrix }}"
  616. matrix_authentication_service_container_labels_internal_compatibility_layer_enabled: "{{ not matrix_authentication_service_migration_in_progress}}"
  617. matrix_authentication_service_container_labels_internal_compatibility_layer_entrypoints: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_name }}"
  618. # MAS somewhat depends on the homeserver service, but the homeserver also depends on MAS.
  619. # To avoid a circular dependency, we make MAS not depend on the homeserver here.
  620. # The homeserver is more lost without MAS than MAS is without the homeserver, so we'll define the dependency on the homeserver side.
  621. # We'll put our dependency on the homeserver as a "want", rather than a requirement.
  622. matrix_authentication_service_systemd_required_services_list_auto: |
  623. {{
  624. ([postgres_identifier ~ '.service'] if postgres_enabled and matrix_authentication_service_config_database_host == postgres_connection_hostname else [])
  625. }}
  626. # See more information about this homeserver "want" in the comment for `matrix_authentication_service_systemd_required_services_list_auto` above.
  627. matrix_authentication_service_systemd_wanted_services_list_auto: |
  628. {{
  629. ['matrix-' + matrix_homeserver_implementation + '.service']
  630. +
  631. ([exim_relay_identifier ~ '.service'] if (exim_relay_enabled and matrix_authentication_service_config_email_transport == 'smtp' and matrix_authentication_service_config_email_hostname == exim_relay_identifier and matrix_authentication_service_container_network != exim_relay_container_network) else [])
  632. }}
  633. matrix_authentication_service_syn2mas_container_network: "{{ postgres_container_network if postgres_enabled and matrix_authentication_service_config_database_host == postgres_connection_hostname else matrix_authentication_service_container_network }}"
  634. matrix_authentication_service_syn2mas_synapse_homeserver_config_path: "{{ matrix_synapse_config_dir_path + '/homeserver.yaml' if matrix_synapse_enabled else '' }}"
  635. ######################################################################
  636. #
  637. # /matrix-authentication-service
  638. #
  639. ######################################################################
  640. ######################################################################
  641. #
  642. # matrix-bridge-appservice-discord
  643. #
  644. ######################################################################
  645. # We don't enable bridges by default.
  646. matrix_appservice_discord_enabled: false
  647. matrix_appservice_discord_systemd_required_services_list_auto: |
  648. {{
  649. matrix_addons_homeserver_systemd_services_list
  650. +
  651. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_discord_database_hostname == postgres_connection_hostname) else [])
  652. }}
  653. matrix_appservice_discord_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9005') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  654. matrix_appservice_discord_container_network: "{{ matrix_addons_container_network }}"
  655. matrix_appservice_discord_container_additional_networks_auto: |-
  656. {{
  657. (
  658. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  659. +
  660. ([postgres_container_network] if (postgres_enabled and matrix_appservice_discord_database_hostname == postgres_connection_hostname and matrix_appservice_discord_container_network != postgres_container_network) else [])
  661. ) | unique
  662. }}
  663. # If the homeserver disables presence, it's likely better (less wasteful) to also disable presence on the bridge side.
  664. matrix_appservice_discord_bridge_disablePresence: "{{ (not matrix_synapse_presence_enabled) if matrix_homeserver_implementation == 'synapse' else false }}"
  665. matrix_appservice_discord_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'discord.as.token', rounds=655555) | to_uuid }}"
  666. matrix_appservice_discord_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'discord.hs.token', rounds=655555) | to_uuid }}"
  667. # We only make this use Postgres if our own Postgres server is enabled.
  668. # It's only then (for now) that we can automatically create the necessary database and user for this service.
  669. matrix_appservice_discord_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  670. matrix_appservice_discord_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  671. matrix_appservice_discord_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.discord.db', rounds=655555) | to_uuid }}"
  672. ######################################################################
  673. #
  674. # /matrix-bridge-appservice-discord
  675. #
  676. ######################################################################
  677. ######################################################################
  678. #
  679. # matrix-appservice-webhooks
  680. #
  681. ######################################################################
  682. # We don't enable bridges by default.
  683. matrix_appservice_webhooks_enabled: false
  684. matrix_appservice_webhooks_hostname: "{{ matrix_server_fqn_matrix }}"
  685. matrix_appservice_webhooks_systemd_required_services_list_auto: |
  686. {{
  687. matrix_addons_homeserver_systemd_services_list
  688. }}
  689. matrix_appservice_webhooks_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  690. matrix_appservice_webhooks_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ matrix_appservice_webhooks_matrix_port) if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  691. matrix_appservice_webhooks_container_network: "{{ matrix_addons_container_network }}"
  692. matrix_appservice_webhooks_container_additional_networks_auto: |-
  693. {{
  694. (
  695. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  696. +
  697. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_appservice_webhooks_container_labels_traefik_enabled) else [])
  698. ) | unique
  699. }}
  700. matrix_appservice_webhooks_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  701. matrix_appservice_webhooks_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  702. matrix_appservice_webhooks_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  703. matrix_appservice_webhooks_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  704. matrix_appservice_webhooks_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'webhook.as.token', rounds=655555) | to_uuid }}"
  705. matrix_appservice_webhooks_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  706. matrix_appservice_webhooks_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'webhook.hs.token', rounds=655555) | to_uuid }}"
  707. matrix_appservice_webhooks_id_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'webhook.id.token', rounds=655555) | to_uuid }}"
  708. ######################################################################
  709. #
  710. # /matrix-appservice-webhooks
  711. #
  712. ######################################################################
  713. ######################################################################
  714. #
  715. # matrix-appservice-slack
  716. #
  717. ######################################################################
  718. # We don't enable bridges by default.
  719. matrix_appservice_slack_enabled: false
  720. matrix_appservice_slack_hostname: "{{ matrix_server_fqn_matrix }}"
  721. matrix_appservice_slack_systemd_required_services_list_auto: |
  722. {{
  723. matrix_addons_homeserver_systemd_services_list
  724. +
  725. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_slack_database_hostname == postgres_connection_hostname) else [])
  726. }}
  727. matrix_appservice_slack_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  728. matrix_appservice_slack_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ matrix_appservice_slack_slack_port) if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  729. matrix_appservice_slack_container_network: "{{ matrix_addons_container_network }}"
  730. matrix_appservice_slack_container_additional_networks_auto: |-
  731. {{
  732. (
  733. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  734. +
  735. ([postgres_container_network] if (postgres_enabled and matrix_appservice_slack_database_hostname == postgres_connection_hostname and matrix_appservice_slack_container_network != postgres_container_network) else [])
  736. +
  737. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_appservice_slack_container_labels_traefik_enabled) else [])
  738. ) | unique
  739. }}
  740. matrix_appservice_slack_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  741. matrix_appservice_slack_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  742. matrix_appservice_slack_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  743. matrix_appservice_slack_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  744. matrix_appservice_slack_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'slack.as.token', rounds=655555) | to_uuid }}"
  745. matrix_appservice_slack_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  746. matrix_appservice_slack_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'slack.hs.token', rounds=655555) | to_uuid }}"
  747. matrix_appservice_slack_id_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'slack.id.token', rounds=655555) | to_uuid }}"
  748. # Postgres is the default, except if not using internal Postgres server
  749. matrix_appservice_slack_database_engine: "{{ 'postgres' if postgres_enabled else 'nedb' }}"
  750. matrix_appservice_slack_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  751. matrix_appservice_slack_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.slack.db', rounds=655555) | to_uuid }}"
  752. matrix_appservice_slack_database_container_network: "{{ postgres_container_network if postgres_enabled else '' }}"
  753. ######################################################################
  754. #
  755. # /matrix-bridge-appservice-slack
  756. #
  757. ######################################################################
  758. ######################################################################
  759. #
  760. # matrix-bridge-appservice-irc
  761. #
  762. ######################################################################
  763. # We don't enable bridges by default.
  764. matrix_appservice_irc_enabled: false
  765. matrix_appservice_irc_systemd_required_services_list_auto: |
  766. {{
  767. matrix_addons_homeserver_systemd_services_list
  768. +
  769. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_irc_database_hostname == postgres_connection_hostname) else [])
  770. }}
  771. matrix_appservice_irc_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  772. matrix_appservice_irc_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9999') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  773. matrix_appservice_irc_container_network: "{{ matrix_addons_container_network }}"
  774. matrix_appservice_irc_container_additional_networks_auto: |-
  775. {{
  776. (
  777. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  778. +
  779. ([postgres_container_network] if (postgres_enabled and matrix_appservice_irc_database_hostname == postgres_connection_hostname and matrix_appservice_irc_container_network != postgres_container_network) else [])
  780. ) | unique
  781. }}
  782. # The IRC bridge docs say that if homeserver presence is disabled, it's better to also disable
  783. # IRC bridge presence, for performance reasons.
  784. matrix_appservice_irc_homeserver_enablePresence: "{{ matrix_synapse_presence_enabled if matrix_homeserver_implementation == 'synapse' else true }}"
  785. matrix_appservice_irc_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'irc.as.token', rounds=655555) | to_uuid }}"
  786. matrix_appservice_irc_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  787. matrix_appservice_irc_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'irc.hs.token', rounds=655555) | to_uuid }}"
  788. matrix_appservice_irc_database_engine: "{{ 'postgres' if postgres_enabled else 'nedb' }}"
  789. matrix_appservice_irc_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  790. matrix_appservice_irc_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.irc.db', rounds=655555) | to_uuid }}"
  791. matrix_appservice_irc_database_container_network: "{{ postgres_container_network if postgres_enabled else '' }}"
  792. ######################################################################
  793. #
  794. # /matrix-bridge-appservice-irc
  795. #
  796. ######################################################################
  797. ######################################################################
  798. #
  799. # matrix-bridge-appservice-kakaotalk
  800. #
  801. ######################################################################
  802. # We don't enable bridges by default.
  803. matrix_appservice_kakaotalk_enabled: false
  804. matrix_appservice_kakaotalk_systemd_required_services_list_auto: |
  805. {{
  806. matrix_addons_homeserver_systemd_services_list
  807. +
  808. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_kakaotalk_database_hostname == postgres_connection_hostname) else [])
  809. }}
  810. matrix_appservice_kakaotalk_container_network: "{{ matrix_addons_container_network }}"
  811. matrix_appservice_kakaotalk_container_additional_networks_auto: |-
  812. {{
  813. (
  814. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  815. +
  816. ([postgres_container_network] if (postgres_enabled and matrix_appservice_kakaotalk_database_hostname == postgres_connection_hostname and matrix_appservice_kakaotalk_container_network != postgres_container_network) else [])
  817. ) | unique
  818. }}
  819. matrix_appservice_kakaotalk_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.kakao.hs', rounds=655555) | to_uuid }}"
  820. matrix_appservice_kakaotalk_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  821. matrix_appservice_kakaotalk_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.kakao.hs', rounds=655555) | to_uuid }}"
  822. matrix_appservice_kakaotalk_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  823. matrix_appservice_kakaotalk_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  824. matrix_appservice_kakaotalk_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  825. matrix_appservice_kakaotalk_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.kakao.db', rounds=655555) | to_uuid }}"
  826. ######################################################################
  827. #
  828. # /matrix-bridge-appservice-kakaotalk
  829. #
  830. ######################################################################
  831. ######################################################################
  832. #
  833. # matrix-bridge-beeper-linkedin
  834. #
  835. ######################################################################
  836. # We don't enable bridges by default.
  837. matrix_beeper_linkedin_enabled: false
  838. matrix_beeper_linkedin_systemd_required_services_list_auto: |
  839. {{
  840. matrix_addons_homeserver_systemd_services_list
  841. +
  842. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_beeper_linkedin_database_hostname == postgres_connection_hostname) else [])
  843. }}
  844. matrix_beeper_linkedin_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  845. matrix_beeper_linkedin_container_network: "{{ matrix_addons_container_network }}"
  846. matrix_beeper_linkedin_container_additional_networks_auto: |-
  847. {{
  848. (
  849. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  850. +
  851. ([postgres_container_network] if (postgres_enabled and matrix_beeper_linkedin_database_hostname == postgres_connection_hostname and matrix_beeper_linkedin_container_network != postgres_container_network) else [])
  852. ) | unique
  853. }}
  854. matrix_beeper_linkedin_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'linked.as.token', rounds=655555) | to_uuid }}"
  855. matrix_beeper_linkedin_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  856. matrix_beeper_linkedin_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'linked.hs.token', rounds=655555) | to_uuid }}"
  857. matrix_beeper_linkedin_bridge_login_shared_secret_map_auto: |-
  858. {{
  859. ({
  860. matrix_beeper_linkedin_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  861. })
  862. if matrix_appservice_double_puppet_enabled
  863. else (
  864. {matrix_beeper_linkedin_homeserver_domain: matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret}
  865. if matrix_synapse_ext_password_provider_shared_secret_auth_enabled
  866. else {}
  867. )
  868. }}
  869. matrix_beeper_linkedin_bridge_presence: "{{ (matrix_synapse_presence_enabled if matrix_synapse_enabled else true) if matrix_homeserver_implementation == 'synapse' else true }}"
  870. matrix_beeper_linkedin_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  871. matrix_beeper_linkedin_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'maulinkedin.db', rounds=655555) | to_uuid }}"
  872. ######################################################################
  873. #
  874. # /matrix-bridge-beeper-linkedin
  875. #
  876. ######################################################################
  877. ######################################################################
  878. #
  879. # matrix-bridge-go-skype-bridge
  880. #
  881. ######################################################################
  882. # We don't enable bridges by default.
  883. matrix_go_skype_bridge_enabled: false
  884. matrix_go_skype_bridge_systemd_required_services_list_auto: |
  885. {{
  886. matrix_addons_homeserver_systemd_services_list
  887. +
  888. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_go_skype_bridge_database_hostname == postgres_connection_hostname) else [])
  889. }}
  890. matrix_go_skype_bridge_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  891. matrix_go_skype_bridge_container_network: "{{ matrix_addons_container_network }}"
  892. matrix_go_skype_bridge_container_additional_networks_auto: |-
  893. {{
  894. (
  895. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  896. +
  897. ([postgres_container_network] if (postgres_enabled and matrix_go_skype_bridge_database_hostname == postgres_connection_hostname and matrix_go_skype_bridge_container_network != postgres_container_network) else [])
  898. ) | unique
  899. }}
  900. matrix_go_skype_bridge_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'skype.as.token', rounds=655555) | to_uuid }}"
  901. matrix_go_skype_bridge_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  902. matrix_go_skype_bridge_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'skype.hs.token', rounds=655555) | to_uuid }}"
  903. matrix_go_skype_bridge_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  904. # Postgres is the default, except if not using internal Postgres server
  905. matrix_go_skype_bridge_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  906. matrix_go_skype_bridge_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  907. matrix_go_skype_bridge_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'goskype.db', rounds=655555) | to_uuid }}"
  908. ######################################################################
  909. #
  910. # /matrix-bridge-go-skype-bridge
  911. #
  912. ######################################################################
  913. ######################################################################
  914. #
  915. # matrix-bridge-mautrix-discord
  916. #
  917. ######################################################################
  918. # We don't enable bridges by default.
  919. matrix_mautrix_discord_enabled: false
  920. matrix_mautrix_discord_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  921. matrix_mautrix_discord_container_network: "{{ matrix_addons_container_network }}"
  922. matrix_mautrix_discord_container_additional_networks_auto: |-
  923. {{
  924. (
  925. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  926. +
  927. ([postgres_container_network] if postgres_enabled and matrix_mautrix_facebook_database_hostname == postgres_connection_hostname else [])
  928. ) | unique
  929. }}
  930. matrix_mautrix_discord_systemd_required_services_list_auto: |
  931. {{
  932. matrix_addons_homeserver_systemd_services_list
  933. +
  934. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_discord_database_hostname == postgres_connection_hostname) else [])
  935. }}
  936. matrix_mautrix_discord_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'maudisc.as.tok', rounds=655555) | to_uuid }}"
  937. matrix_mautrix_discord_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  938. matrix_mautrix_discord_homeserver_public_address: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}://{{ matrix_server_fqn_matrix }}"
  939. matrix_mautrix_discord_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'maudisc.hs.tok', rounds=655555) | to_uuid }}"
  940. matrix_mautrix_discord_bridge_login_shared_secret_map_auto: |-
  941. {{
  942. ({
  943. matrix_mautrix_discord_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  944. })
  945. if matrix_appservice_double_puppet_enabled
  946. else (
  947. {matrix_mautrix_discord_homeserver_domain: matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret}
  948. if matrix_synapse_ext_password_provider_shared_secret_auth_enabled
  949. else {}
  950. )
  951. }}
  952. # Postgres is the default, except if not using internal Postgres server
  953. matrix_mautrix_discord_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  954. matrix_mautrix_discord_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  955. matrix_mautrix_discord_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'maudiscord.db', rounds=655555) | to_uuid }}"
  956. ######################################################################
  957. #
  958. # /matrix-bridge-mautrix-discord
  959. #
  960. ######################################################################
  961. ######################################################################
  962. #
  963. # matrix-bridge-mautrix-slack
  964. #
  965. ######################################################################
  966. # We don't enable bridges by default.
  967. matrix_mautrix_slack_enabled: false
  968. matrix_mautrix_slack_systemd_required_services_list_auto: |
  969. {{
  970. matrix_addons_homeserver_systemd_services_list
  971. +
  972. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_slack_database_hostname == postgres_connection_hostname) else [])
  973. }}
  974. matrix_mautrix_slack_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  975. matrix_mautrix_slack_container_network: "{{ matrix_addons_container_network }}"
  976. matrix_mautrix_slack_container_additional_networks_auto: |-
  977. {{
  978. (
  979. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  980. +
  981. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_slack_database_hostname == postgres_connection_hostname and matrix_mautrix_slack_container_network != postgres_container_network) else [])
  982. ) | unique
  983. }}
  984. matrix_mautrix_slack_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mauslack.as.tok', rounds=655555) | to_uuid }}"
  985. matrix_mautrix_slack_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  986. matrix_mautrix_slack_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mauslack.hs.tok', rounds=655555) | to_uuid }}"
  987. matrix_mautrix_slack_double_puppet_secrets_auto: |-
  988. {{
  989. {
  990. matrix_mautrix_slack_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  991. }
  992. if matrix_appservice_double_puppet_enabled
  993. else {}
  994. }}
  995. # Postgres is the default, except if not using internal Postgres server
  996. matrix_mautrix_slack_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  997. matrix_mautrix_slack_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  998. matrix_mautrix_slack_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mauslack.db', rounds=655555) | to_uuid }}"
  999. matrix_mautrix_slack_provisioning_shared_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.slack.prov', rounds=655555) | to_uuid }}"
  1000. matrix_mautrix_slack_public_media_signing_key: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.slack.pmed', rounds=655555) | to_uuid }}"
  1001. ######################################################################
  1002. #
  1003. # /matrix-bridge-mautrix-slack
  1004. #
  1005. ######################################################################
  1006. ######################################################################
  1007. #
  1008. # matrix-bridge-mautrix-facebook
  1009. #
  1010. ######################################################################
  1011. # We don't enable bridges by default.
  1012. matrix_mautrix_facebook_enabled: false
  1013. matrix_mautrix_facebook_systemd_required_services_list_auto: |
  1014. {{
  1015. matrix_addons_homeserver_systemd_services_list
  1016. +
  1017. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_facebook_database_hostname == postgres_connection_hostname) else [])
  1018. }}
  1019. matrix_mautrix_facebook_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1020. matrix_mautrix_facebook_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9008') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  1021. matrix_mautrix_facebook_container_network: "{{ matrix_addons_container_network }}"
  1022. matrix_mautrix_facebook_container_additional_networks_auto: |-
  1023. {{
  1024. (
  1025. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1026. +
  1027. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_facebook_database_hostname == postgres_connection_hostname and matrix_mautrix_facebook_container_network != postgres_container_network) else [])
  1028. +
  1029. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_facebook_container_labels_traefik_enabled) else [])
  1030. ) | unique
  1031. }}
  1032. matrix_mautrix_facebook_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1033. matrix_mautrix_facebook_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1034. matrix_mautrix_facebook_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1035. matrix_mautrix_facebook_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1036. matrix_mautrix_facebook_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1037. matrix_mautrix_facebook_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1038. matrix_mautrix_facebook_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'fb.as.token', rounds=655555) | to_uuid }}"
  1039. matrix_mautrix_facebook_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1040. matrix_mautrix_facebook_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'fb.hs.token', rounds=655555) | to_uuid }}"
  1041. matrix_mautrix_facebook_appservice_public_enabled: true
  1042. matrix_mautrix_facebook_appservice_public_hostname: "{{ matrix_server_fqn_matrix }}"
  1043. matrix_mautrix_facebook_appservice_public_prefix: "/{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'facebook', rounds=655555) | to_uuid }}"
  1044. matrix_mautrix_facebook_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1045. matrix_mautrix_facebook_bridge_presence: "{{ (matrix_synapse_presence_enabled if matrix_synapse_enabled else true) if matrix_homeserver_implementation == 'synapse' else true }}"
  1046. matrix_mautrix_facebook_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1047. matrix_mautrix_facebook_metrics_proxying_enabled: "{{ matrix_mautrix_facebook_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1048. matrix_mautrix_facebook_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1049. matrix_mautrix_facebook_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-facebook"
  1050. # We'd like to force-set people with external Postgres to SQLite, so the bridge role can complain
  1051. # and point them to a migration path.
  1052. matrix_mautrix_facebook_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1053. matrix_mautrix_facebook_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1054. matrix_mautrix_facebook_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.fb.db', rounds=655555) | to_uuid }}"
  1055. ######################################################################
  1056. #
  1057. # /matrix-bridge-mautrix-facebook
  1058. #
  1059. ######################################################################
  1060. ######################################################################
  1061. #
  1062. # matrix-bridge-mautrix-googlechat
  1063. #
  1064. ######################################################################
  1065. # We don't enable bridges by default.
  1066. matrix_mautrix_googlechat_enabled: false
  1067. matrix_mautrix_googlechat_systemd_required_services_list_auto: |
  1068. {{
  1069. matrix_addons_homeserver_systemd_services_list
  1070. +
  1071. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_googlechat_database_hostname == postgres_connection_hostname) else [])
  1072. }}
  1073. matrix_mautrix_googlechat_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1074. matrix_mautrix_googlechat_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9007') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  1075. matrix_mautrix_googlechat_container_network: "{{ matrix_addons_container_network }}"
  1076. matrix_mautrix_googlechat_container_additional_networks_auto: |-
  1077. {{
  1078. (
  1079. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1080. +
  1081. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_googlechat_database_hostname == postgres_connection_hostname and matrix_mautrix_googlechat_container_network != postgres_container_network) else [])
  1082. +
  1083. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_gmessages_container_labels_traefik_enabled) else [])
  1084. ) | unique
  1085. }}
  1086. matrix_mautrix_googlechat_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1087. matrix_mautrix_googlechat_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1088. matrix_mautrix_googlechat_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1089. matrix_mautrix_googlechat_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1090. matrix_mautrix_googlechat_container_labels_public_endpoint_hostname: "{{ matrix_server_fqn_matrix }}"
  1091. matrix_mautrix_googlechat_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1092. matrix_mautrix_googlechat_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1093. matrix_mautrix_googlechat_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'gc.as.token', rounds=655555) | to_uuid }}"
  1094. matrix_mautrix_googlechat_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1095. matrix_mautrix_googlechat_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'gc.hs.token', rounds=655555) | to_uuid }}"
  1096. matrix_mautrix_googlechat_login_shared_secret: |-
  1097. {{
  1098. ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1099. if matrix_appservice_double_puppet_enabled
  1100. else (
  1101. matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled
  1102. if matrix_synapse_ext_password_provider_shared_secret_auth_enabled
  1103. else ""
  1104. )
  1105. }}
  1106. matrix_mautrix_googlechat_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1107. matrix_mautrix_googlechat_metrics_proxying_enabled: "{{ matrix_mautrix_googlechat_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1108. matrix_mautrix_googlechat_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1109. matrix_mautrix_googlechat_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-googlechat"
  1110. # Postgres is the default, except if not using internal Postgres server
  1111. matrix_mautrix_googlechat_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1112. matrix_mautrix_googlechat_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1113. matrix_mautrix_googlechat_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.gc.db', rounds=655555) | to_uuid }}"
  1114. ######################################################################
  1115. #
  1116. # /matrix-bridge-mautrix-googlechat
  1117. #
  1118. ######################################################################
  1119. ######################################################################
  1120. #
  1121. # matrix-bridge-mautrix-hangouts
  1122. #
  1123. ######################################################################
  1124. # We don't enable bridges by default.
  1125. matrix_mautrix_hangouts_enabled: false
  1126. matrix_mautrix_hangouts_systemd_required_services_list_auto: |
  1127. {{
  1128. matrix_addons_homeserver_systemd_services_list
  1129. +
  1130. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_hangouts_database_hostname == postgres_connection_hostname) else [])
  1131. }}
  1132. matrix_mautrix_hangouts_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1133. matrix_mautrix_hangouts_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9007') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  1134. matrix_mautrix_hangouts_container_network: "{{ matrix_addons_container_network }}"
  1135. matrix_mautrix_hangouts_container_additional_networks_auto: |-
  1136. {{
  1137. (
  1138. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1139. +
  1140. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_hangouts_database_hostname == postgres_connection_hostname and matrix_mautrix_hangouts_container_network != postgres_container_network) else [])
  1141. +
  1142. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_gmessages_container_labels_traefik_enabled) else [])
  1143. ) | unique
  1144. }}
  1145. matrix_mautrix_hangouts_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1146. matrix_mautrix_hangouts_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1147. matrix_mautrix_hangouts_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1148. matrix_mautrix_hangouts_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1149. matrix_mautrix_hangouts_container_labels_public_endpoint_hostname: "{{ matrix_server_fqn_matrix }}"
  1150. matrix_mautrix_hangouts_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1151. matrix_mautrix_hangouts_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1152. matrix_mautrix_hangouts_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ho.as.token', rounds=655555) | to_uuid }}"
  1153. matrix_mautrix_hangouts_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1154. matrix_mautrix_hangouts_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ho.hs.token', rounds=655555) | to_uuid }}"
  1155. matrix_mautrix_hangouts_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1156. matrix_mautrix_hangouts_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1157. matrix_mautrix_hangouts_metrics_proxying_enabled: "{{ matrix_mautrix_hangouts_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1158. matrix_mautrix_hangouts_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1159. matrix_mautrix_hangouts_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-hangouts"
  1160. # Postgres is the default, except if not using internal Postgres server
  1161. matrix_mautrix_hangouts_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1162. matrix_mautrix_hangouts_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1163. matrix_mautrix_hangouts_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.hangouts.db', rounds=655555) | to_uuid }}"
  1164. ######################################################################
  1165. #
  1166. # /matrix-bridge-mautrix-hangouts
  1167. #
  1168. ######################################################################
  1169. ######################################################################
  1170. #
  1171. # matrix-bridge-mautrix-instagram
  1172. #
  1173. ######################################################################
  1174. # We don't enable bridges by default.
  1175. matrix_mautrix_instagram_enabled: false
  1176. matrix_mautrix_instagram_systemd_required_services_list_auto: |
  1177. {{
  1178. matrix_addons_homeserver_systemd_services_list
  1179. +
  1180. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_instagram_database_hostname == postgres_connection_hostname) else [])
  1181. }}
  1182. matrix_mautrix_instagram_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1183. matrix_mautrix_instagram_container_network: "{{ matrix_addons_container_network }}"
  1184. matrix_mautrix_instagram_container_additional_networks_auto: |-
  1185. {{
  1186. (
  1187. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1188. +
  1189. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_instagram_database_hostname == postgres_connection_hostname and matrix_mautrix_instagram_container_network != postgres_container_network) else [])
  1190. +
  1191. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_instagram_container_labels_traefik_enabled else [])
  1192. ) | unique
  1193. }}
  1194. matrix_mautrix_instagram_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1195. matrix_mautrix_instagram_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1196. matrix_mautrix_instagram_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1197. matrix_mautrix_instagram_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1198. matrix_mautrix_instagram_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1199. matrix_mautrix_instagram_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1200. matrix_mautrix_instagram_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ig.as.token', rounds=655555) | to_uuid }}"
  1201. matrix_mautrix_instagram_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1202. matrix_mautrix_instagram_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ig.hs.token', rounds=655555) | to_uuid }}"
  1203. matrix_mautrix_instagram_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1204. matrix_mautrix_instagram_bridge_presence: "{{ (matrix_synapse_presence_enabled if matrix_synapse_enabled else true) if matrix_homeserver_implementation == 'synapse' else true }}"
  1205. matrix_mautrix_instagram_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1206. matrix_mautrix_instagram_metrics_proxying_enabled: "{{ matrix_mautrix_instagram_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1207. matrix_mautrix_instagram_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1208. matrix_mautrix_instagram_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-instagram"
  1209. # We'd like to force-set people with external Postgres to SQLite, so the bridge role can complain
  1210. # and point them to a migration path.
  1211. matrix_mautrix_instagram_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1212. matrix_mautrix_instagram_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1213. matrix_mautrix_instagram_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.ig.db', rounds=655555) | to_uuid }}"
  1214. ######################################################################
  1215. #
  1216. # /matrix-bridge-mautrix-instagram
  1217. #
  1218. ######################################################################
  1219. ######################################################################
  1220. #
  1221. # matrix-bridge-mautrix-signal
  1222. #
  1223. ######################################################################
  1224. # We don't enable bridges by default.
  1225. matrix_mautrix_signal_enabled: false
  1226. matrix_mautrix_signal_systemd_required_services_list_auto: |
  1227. {{
  1228. matrix_addons_homeserver_systemd_services_list
  1229. +
  1230. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_signal_database_hostname == postgres_connection_hostname) else [])
  1231. }}
  1232. matrix_mautrix_signal_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1233. matrix_mautrix_signal_container_network: "{{ matrix_addons_container_network }}"
  1234. matrix_mautrix_signal_container_additional_networks_auto: |-
  1235. {{
  1236. (
  1237. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1238. +
  1239. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_signal_database_hostname == postgres_connection_hostname and matrix_mautrix_signal_container_network != postgres_container_network) else [])
  1240. +
  1241. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_signal_container_labels_traefik_enabled else [])
  1242. ) | unique
  1243. }}
  1244. matrix_mautrix_signal_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1245. matrix_mautrix_signal_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1246. matrix_mautrix_signal_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1247. matrix_mautrix_signal_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1248. matrix_mautrix_signal_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1249. matrix_mautrix_signal_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1250. matrix_mautrix_signal_homeserver_domain: '{{ matrix_domain }}'
  1251. matrix_mautrix_signal_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1252. matrix_mautrix_signal_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'si.hs.token', rounds=655555) | to_uuid }}"
  1253. matrix_mautrix_signal_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'si.as.token', rounds=655555) | to_uuid }}"
  1254. matrix_mautrix_signal_double_puppet_secrets_auto: |-
  1255. {{
  1256. {
  1257. matrix_mautrix_signal_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1258. }
  1259. if matrix_appservice_double_puppet_enabled
  1260. else {}
  1261. }}
  1262. matrix_mautrix_signal_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1263. matrix_mautrix_signal_metrics_proxying_enabled: "{{ matrix_mautrix_signal_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1264. matrix_mautrix_signal_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1265. matrix_mautrix_signal_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-signal"
  1266. matrix_mautrix_signal_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1267. matrix_mautrix_signal_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1268. matrix_mautrix_signal_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.signal.db', rounds=655555) | to_uuid }}"
  1269. matrix_mautrix_signal_provisioning_shared_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.signal.prov', rounds=655555) | to_uuid }}"
  1270. matrix_mautrix_signal_public_media_signing_key: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.signal.pmed', rounds=655555) | to_uuid }}"
  1271. ######################################################################
  1272. #
  1273. # /matrix-bridge-mautrix-signal
  1274. #
  1275. ######################################################################
  1276. ######################################################################
  1277. #
  1278. # matrix-bridge-mautrix-meta-messenger
  1279. #
  1280. ######################################################################
  1281. # We don't enable bridges by default.
  1282. matrix_mautrix_meta_messenger_enabled: false
  1283. matrix_mautrix_meta_messenger_systemd_required_services_list_auto: |
  1284. {{
  1285. matrix_addons_homeserver_systemd_services_list
  1286. +
  1287. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_meta_messenger_database_hostname == postgres_connection_hostname) else [])
  1288. }}
  1289. matrix_mautrix_meta_messenger_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1290. matrix_mautrix_meta_messenger_container_network: "{{ matrix_addons_container_network }}"
  1291. matrix_mautrix_meta_messenger_container_additional_networks_auto: |-
  1292. {{
  1293. (
  1294. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1295. +
  1296. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_meta_messenger_database_hostname == postgres_connection_hostname and matrix_mautrix_meta_messenger_container_network != postgres_container_network) else [])
  1297. +
  1298. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_meta_messenger_container_labels_traefik_enabled) else [])
  1299. ) | unique
  1300. }}
  1301. matrix_mautrix_meta_messenger_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1302. matrix_mautrix_meta_messenger_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1303. matrix_mautrix_meta_messenger_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1304. matrix_mautrix_meta_messenger_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1305. matrix_mautrix_meta_messenger_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1306. matrix_mautrix_meta_messenger_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1307. matrix_mautrix_meta_messenger_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.meta.fb.as', rounds=655555) | to_uuid }}"
  1308. matrix_mautrix_meta_messenger_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1309. matrix_mautrix_meta_messenger_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.meta.fb.hs', rounds=655555) | to_uuid }}"
  1310. matrix_mautrix_meta_messenger_double_puppet_secrets_auto: |-
  1311. {{
  1312. {
  1313. matrix_mautrix_meta_messenger_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1314. }
  1315. if matrix_appservice_double_puppet_enabled
  1316. else {}
  1317. }}
  1318. matrix_mautrix_meta_messenger_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1319. matrix_mautrix_meta_messenger_metrics_proxying_enabled: "{{ matrix_mautrix_meta_messenger_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1320. matrix_mautrix_meta_messenger_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1321. matrix_mautrix_meta_messenger_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-meta-messenger"
  1322. # We'd like to force-set people with external Postgres to SQLite, so the bridge role can complain
  1323. # and point them to a migration path.
  1324. matrix_mautrix_meta_messenger_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite3-fk-wal' }}"
  1325. matrix_mautrix_meta_messenger_database_hostname: "{{ postgres_connection_hostname if (postgres_enabled and matrix_mautrix_meta_messenger_database_engine == 'postgres') else '' }}"
  1326. matrix_mautrix_meta_messenger_database_password: "{{ ('%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.fb.db', rounds=655555) | to_uuid) if (postgres_enabled and matrix_mautrix_meta_messenger_database_engine == 'postgres') else '' }}"
  1327. ######################################################################
  1328. #
  1329. # /matrix-bridge-mautrix-meta-messenger
  1330. #
  1331. ######################################################################
  1332. ######################################################################
  1333. #
  1334. # matrix-bridge-mautrix-meta-instagram
  1335. #
  1336. ######################################################################
  1337. # We don't enable bridges by default.
  1338. matrix_mautrix_meta_instagram_enabled: false
  1339. matrix_mautrix_meta_instagram_systemd_required_services_list_auto: |
  1340. {{
  1341. matrix_addons_homeserver_systemd_services_list
  1342. +
  1343. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_meta_instagram_database_hostname == postgres_connection_hostname) else [])
  1344. }}
  1345. matrix_mautrix_meta_instagram_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1346. matrix_mautrix_meta_instagram_container_network: "{{ matrix_addons_container_network }}"
  1347. matrix_mautrix_meta_instagram_container_additional_networks_auto: |-
  1348. {{
  1349. (
  1350. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1351. +
  1352. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_meta_instagram_database_hostname == postgres_connection_hostname and matrix_mautrix_meta_instagram_container_network != postgres_container_network) else [])
  1353. +
  1354. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_meta_instagram_container_labels_traefik_enabled) else [])
  1355. ) | unique
  1356. }}
  1357. matrix_mautrix_meta_instagram_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1358. matrix_mautrix_meta_instagram_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1359. matrix_mautrix_meta_instagram_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1360. matrix_mautrix_meta_instagram_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1361. matrix_mautrix_meta_instagram_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1362. matrix_mautrix_meta_instagram_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1363. matrix_mautrix_meta_instagram_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.meta.ig.as', rounds=655555) | to_uuid }}"
  1364. matrix_mautrix_meta_instagram_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1365. matrix_mautrix_meta_instagram_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.meta.ig.hs', rounds=655555) | to_uuid }}"
  1366. matrix_mautrix_meta_instagram_double_puppet_secrets_auto: |-
  1367. {{
  1368. {
  1369. matrix_mautrix_meta_instagram_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1370. }
  1371. if matrix_appservice_double_puppet_enabled
  1372. else {}
  1373. }}
  1374. matrix_mautrix_meta_instagram_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1375. matrix_mautrix_meta_instagram_metrics_proxying_enabled: "{{ matrix_mautrix_meta_instagram_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1376. matrix_mautrix_meta_instagram_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1377. matrix_mautrix_meta_instagram_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-meta-instagram"
  1378. # We'd like to force-set people with external Postgres to SQLite, so the bridge role can complain
  1379. # and point them to a migration path.
  1380. matrix_mautrix_meta_instagram_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite3-fk-wal' }}"
  1381. matrix_mautrix_meta_instagram_database_hostname: "{{ postgres_connection_hostname if (postgres_enabled and matrix_mautrix_meta_instagram_database_engine == 'postgres') else '' }}"
  1382. matrix_mautrix_meta_instagram_database_password: "{{ ('%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.fb.db', rounds=655555) | to_uuid) if (postgres_enabled and matrix_mautrix_meta_instagram_database_engine == 'postgres') else '' }}"
  1383. ######################################################################
  1384. #
  1385. # /matrix-bridge-mautrix-meta-instagram
  1386. #
  1387. ######################################################################
  1388. ######################################################################
  1389. #
  1390. # matrix-bridge-mautrix-telegram
  1391. #
  1392. ######################################################################
  1393. # We don't enable bridges by default.
  1394. matrix_mautrix_telegram_enabled: false
  1395. matrix_mautrix_telegram_hostname: "{{ matrix_server_fqn_matrix }}"
  1396. matrix_mautrix_telegram_path_prefix: "/{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'telegram', rounds=655555) | to_uuid }}"
  1397. matrix_mautrix_telegram_systemd_required_services_list_auto: |
  1398. {{
  1399. matrix_addons_homeserver_systemd_services_list
  1400. +
  1401. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_telegram_database_hostname == postgres_connection_hostname) else [])
  1402. }}
  1403. # Images are multi-arch (amd64 and arm64, but not arm32).
  1404. matrix_mautrix_telegram_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1405. matrix_telegram_lottieconverter_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1406. matrix_telegram_lottieconverter_container_image_self_build_mask_arch: "{{ matrix_architecture != 'amd64' }}"
  1407. matrix_mautrix_telegram_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9006') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  1408. matrix_mautrix_telegram_container_network: "{{ matrix_addons_container_network }}"
  1409. matrix_mautrix_telegram_container_additional_networks_auto: |-
  1410. {{
  1411. (
  1412. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1413. +
  1414. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_telegram_database_hostname == postgres_connection_hostname and matrix_mautrix_telegram_container_network != postgres_container_network) else [])
  1415. +
  1416. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_telegram_container_labels_traefik_enabled) else [])
  1417. ) | unique
  1418. }}
  1419. matrix_mautrix_telegram_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1420. matrix_mautrix_telegram_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1421. matrix_mautrix_telegram_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1422. matrix_mautrix_telegram_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1423. matrix_mautrix_telegram_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1424. matrix_mautrix_telegram_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1425. matrix_mautrix_telegram_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'telegr.as.token', rounds=655555) | to_uuid }}"
  1426. matrix_mautrix_telegram_homeserver_domain: "{{ matrix_domain }}"
  1427. matrix_mautrix_telegram_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1428. matrix_mautrix_telegram_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'telegr.hs.token', rounds=655555) | to_uuid }}"
  1429. matrix_mautrix_telegram_bridge_login_shared_secret_map_auto: |-
  1430. {{
  1431. ({
  1432. matrix_mautrix_telegram_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1433. })
  1434. if matrix_appservice_double_puppet_enabled
  1435. else (
  1436. {matrix_mautrix_telegram_homeserver_domain: matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret}
  1437. if matrix_synapse_ext_password_provider_shared_secret_auth_enabled
  1438. else {}
  1439. )
  1440. }}
  1441. matrix_mautrix_telegram_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1442. matrix_mautrix_telegram_metrics_proxying_enabled: "{{ matrix_mautrix_telegram_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1443. matrix_mautrix_telegram_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1444. matrix_mautrix_telegram_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-telegram"
  1445. # Postgres is the default, except if not using internal Postgres server
  1446. matrix_mautrix_telegram_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1447. matrix_mautrix_telegram_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1448. matrix_mautrix_telegram_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.telegram.db', rounds=655555) | to_uuid }}"
  1449. ######################################################################
  1450. #
  1451. # /matrix-bridge-mautrix-telegram
  1452. #
  1453. ######################################################################
  1454. ######################################################################
  1455. #
  1456. # matrix-bridge-mautrix-twitter
  1457. #
  1458. ######################################################################
  1459. # We don't enable bridges by default.
  1460. matrix_mautrix_twitter_enabled: false
  1461. matrix_mautrix_twitter_systemd_required_services_list_auto: |
  1462. {{
  1463. matrix_addons_homeserver_systemd_services_list
  1464. +
  1465. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_twitter_database_hostname == postgres_connection_hostname) else [])
  1466. }}
  1467. matrix_mautrix_twitter_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1468. matrix_mautrix_twitter_container_network: "{{ matrix_addons_container_network }}"
  1469. matrix_mautrix_twitter_container_additional_networks_auto: |-
  1470. {{
  1471. (
  1472. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1473. +
  1474. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_twitter_database_hostname == postgres_connection_hostname and matrix_mautrix_twitter_container_network != postgres_container_network) else [])
  1475. +
  1476. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_twitter_container_labels_traefik_enabled else [])
  1477. ) | unique
  1478. }}
  1479. matrix_mautrix_twitter_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1480. matrix_mautrix_twitter_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1481. matrix_mautrix_twitter_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1482. matrix_mautrix_twitter_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1483. matrix_mautrix_twitter_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1484. matrix_mautrix_twitter_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1485. matrix_mautrix_twitter_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'twt.as.token', rounds=655555) | to_uuid }}"
  1486. matrix_mautrix_twitter_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1487. matrix_mautrix_twitter_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'twt.hs.token', rounds=655555) | to_uuid }}"
  1488. matrix_mautrix_twitter_bridge_login_shared_secret_map_auto: |-
  1489. {{
  1490. ({
  1491. matrix_mautrix_twitter_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1492. })
  1493. if matrix_appservice_double_puppet_enabled
  1494. else (
  1495. {matrix_mautrix_twitter_homeserver_domain: matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret}
  1496. if matrix_synapse_ext_password_provider_shared_secret_auth_enabled
  1497. else {}
  1498. )
  1499. }}
  1500. matrix_mautrix_twitter_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1501. matrix_mautrix_twitter_metrics_proxying_enabled: "{{ matrix_mautrix_twitter_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1502. matrix_mautrix_twitter_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1503. matrix_mautrix_twitter_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-twitter"
  1504. matrix_mautrix_twitter_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1505. matrix_mautrix_twitter_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mau.twt.db', rounds=655555) | to_uuid if postgres_enabled else '' }}"
  1506. ######################################################################
  1507. #
  1508. # /matrix-bridge-mautrix-twitter
  1509. #
  1510. ######################################################################
  1511. ######################################################################
  1512. #
  1513. # matrix-bridge-mautrix-gmessages
  1514. #
  1515. ######################################################################
  1516. # We don't enable bridges by default.
  1517. matrix_mautrix_gmessages_enabled: false
  1518. matrix_mautrix_gmessages_systemd_required_services_list_auto: |
  1519. {{
  1520. matrix_addons_homeserver_systemd_services_list
  1521. +
  1522. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_facebook_database_hostname == postgres_connection_hostname) else [])
  1523. }}
  1524. matrix_mautrix_gmessages_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1525. matrix_mautrix_gmessages_container_network: "{{ matrix_addons_container_network }}"
  1526. matrix_mautrix_gmessages_container_additional_networks_auto: |-
  1527. {{
  1528. (
  1529. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1530. +
  1531. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_gmessages_database_hostname == postgres_connection_hostname and matrix_mautrix_gmessages_container_network != postgres_container_network) else [])
  1532. +
  1533. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_gmessages_container_labels_traefik_enabled) else [])
  1534. ) | unique
  1535. }}
  1536. matrix_mautrix_gmessages_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1537. matrix_mautrix_gmessages_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1538. matrix_mautrix_gmessages_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1539. matrix_mautrix_gmessages_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1540. matrix_mautrix_gmessages_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1541. matrix_mautrix_gmessages_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1542. matrix_mautrix_gmessages_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'gmessa.as.token', rounds=655555) | to_uuid }}"
  1543. matrix_mautrix_gmessages_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1544. matrix_mautrix_gmessages_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'gmessa.hs.token', rounds=655555) | to_uuid }}"
  1545. matrix_mautrix_gmessages_double_puppet_secrets_auto: |-
  1546. {{
  1547. {
  1548. matrix_mautrix_gmessages_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1549. }
  1550. if matrix_appservice_double_puppet_enabled
  1551. else {}
  1552. }}
  1553. matrix_mautrix_gmessages_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1554. matrix_mautrix_gmessages_metrics_proxying_enabled: "{{ matrix_mautrix_gmessages_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1555. matrix_mautrix_gmessages_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1556. matrix_mautrix_gmessages_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-gmessages"
  1557. # Postgres is the default, except if not using internal Postgres server
  1558. matrix_mautrix_gmessages_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1559. matrix_mautrix_gmessages_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1560. matrix_mautrix_gmessages_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'maugmessages.db', rounds=655555) | to_uuid }}"
  1561. ######################################################################
  1562. #
  1563. # /matrix-bridge-mautrix-gmessages
  1564. #
  1565. ######################################################################
  1566. ######################################################################
  1567. #
  1568. # matrix-bridge-mautrix-wsproxy
  1569. #
  1570. ######################################################################
  1571. # We don't enable bridges by default.
  1572. matrix_mautrix_wsproxy_enabled: false
  1573. matrix_mautrix_wsproxy_systemd_required_services_list_default: |
  1574. {{
  1575. matrix_addons_homeserver_systemd_services_list
  1576. +
  1577. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_wsproxy_syncproxy_database_hostname == postgres_connection_hostname) else [])
  1578. }}
  1579. matrix_mautrix_wsproxy_homeserver_domain: "{{ matrix_domain }}"
  1580. matrix_mautrix_wsproxy_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1581. matrix_mautrix_wsproxy_hostname: "wsproxy.{{ matrix_mautrix_wsproxy_homeserver_domain }}"
  1582. matrix_mautrix_wsproxy_syncproxy_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  1583. matrix_mautrix_wsproxy_container_network: "{{ matrix_addons_container_network }}"
  1584. matrix_mautrix_wsproxy_container_additional_networks: |
  1585. {{
  1586. (
  1587. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1588. +
  1589. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  1590. +
  1591. ([postgres_container_network] if (postgres_enabled and matrix_mautrix_wsproxy_syncproxy_database_hostname == postgres_connection_hostname and postgres_container_network != matrix_mautrix_wsproxy_container_network) else [])
  1592. ) | unique
  1593. }}
  1594. matrix_mautrix_wsproxy_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1595. matrix_mautrix_wsproxy_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1596. matrix_mautrix_wsproxy_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1597. matrix_mautrix_wsproxy_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1598. matrix_mautrix_wsproxy_syncproxy_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1599. matrix_mautrix_wsproxy_syncproxy_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'wsproxy.db', rounds=655555) | to_uuid }}"
  1600. ######################################################################
  1601. #
  1602. # /matrix-bridge-mautrix-wsproxy
  1603. #
  1604. ######################################################################
  1605. ######################################################################
  1606. #
  1607. # matrix-bridge-wechat
  1608. #
  1609. ######################################################################
  1610. # We don't enable bridges by default.
  1611. matrix_wechat_enabled: false
  1612. matrix_wechat_systemd_required_services_list_auto: |
  1613. {{
  1614. matrix_addons_homeserver_systemd_services_list
  1615. +
  1616. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_wechat_database_hostname == postgres_connection_hostname) else [])
  1617. }}
  1618. matrix_wechat_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  1619. matrix_wechat_agent_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  1620. matrix_wechat_container_network: "{{ matrix_addons_container_network }}"
  1621. matrix_wechat_container_additional_networks_auto: |-
  1622. {{
  1623. (
  1624. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1625. +
  1626. ([postgres_container_network] if (postgres_enabled and matrix_wechat_database_hostname == postgres_connection_hostname and matrix_wechat_container_network != postgres_container_network) else [])
  1627. ) | unique
  1628. }}
  1629. matrix_wechat_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'wechat.as.token', rounds=655555) | to_uuid }}"
  1630. matrix_wechat_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1631. matrix_wechat_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'wechat.hs.token', rounds=655555) | to_uuid }}"
  1632. matrix_wechat_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1633. matrix_wechat_bridge_listen_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'wechat.lstn', rounds=655555) | to_uuid }}"
  1634. # Postgres is the default, except if not using internal Postgres server
  1635. matrix_wechat_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1636. matrix_wechat_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1637. matrix_wechat_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'gowechat.db', rounds=655555) | to_uuid }}"
  1638. ######################################################################
  1639. #
  1640. # /matrix-bridge-wechat
  1641. #
  1642. ######################################################################
  1643. ######################################################################
  1644. #
  1645. # matrix-bridge-mautrix-whatsapp
  1646. #
  1647. ######################################################################
  1648. # We don't enable bridges by default.
  1649. matrix_mautrix_whatsapp_enabled: false
  1650. matrix_mautrix_whatsapp_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1651. matrix_mautrix_whatsapp_container_network: "{{ matrix_addons_container_network }}"
  1652. matrix_mautrix_whatsapp_container_additional_networks_auto: |-
  1653. {{
  1654. (
  1655. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1656. +
  1657. ([postgres_container_network] if postgres_enabled and matrix_mautrix_whatsapp_database_hostname == postgres_connection_hostname else [])
  1658. +
  1659. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_mautrix_whatsapp_container_labels_traefik_enabled else [])
  1660. ) | unique
  1661. }}
  1662. matrix_mautrix_whatsapp_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1663. matrix_mautrix_whatsapp_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1664. matrix_mautrix_whatsapp_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1665. matrix_mautrix_whatsapp_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1666. matrix_mautrix_whatsapp_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1667. matrix_mautrix_whatsapp_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1668. matrix_mautrix_whatsapp_systemd_required_services_list_auto: |
  1669. {{
  1670. matrix_addons_homeserver_systemd_services_list
  1671. +
  1672. ([postgres_identifier ~ '.service'] if postgres_enabled and matrix_mautrix_whatsapp_database_hostname == postgres_connection_hostname else [])
  1673. }}
  1674. matrix_mautrix_whatsapp_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'whats.as.token', rounds=655555) | to_uuid }}"
  1675. matrix_mautrix_whatsapp_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1676. matrix_mautrix_whatsapp_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'whats.hs.token', rounds=655555) | to_uuid }}"
  1677. matrix_mautrix_whatsapp_double_puppet_secrets_auto: |-
  1678. {{
  1679. {
  1680. matrix_mautrix_whatsapp_homeserver_domain: ("as_token:" + matrix_appservice_double_puppet_registration_as_token)
  1681. }
  1682. if matrix_appservice_double_puppet_enabled
  1683. else {}
  1684. }}
  1685. matrix_mautrix_whatsapp_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1686. matrix_mautrix_whatsapp_metrics_proxying_enabled: "{{ matrix_mautrix_whatsapp_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1687. matrix_mautrix_whatsapp_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1688. matrix_mautrix_whatsapp_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/mautrix-whatsapp"
  1689. # Postgres is the default, except if not using internal Postgres server
  1690. matrix_mautrix_whatsapp_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1691. matrix_mautrix_whatsapp_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1692. matrix_mautrix_whatsapp_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mauwhatsapp.db', rounds=655555) | to_uuid }}"
  1693. ######################################################################
  1694. #
  1695. # /matrix-bridge-mautrix-whatsapp
  1696. #
  1697. ######################################################################
  1698. ######################################################################
  1699. #
  1700. # matrix-sms-bridge
  1701. #
  1702. ######################################################################
  1703. # We don't enable bridges by default.
  1704. matrix_sms_bridge_enabled: false
  1705. matrix_sms_bridge_systemd_required_services_list_auto: |
  1706. {{
  1707. matrix_addons_homeserver_systemd_services_list
  1708. +
  1709. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mautrix_facebook_database_hostname == postgres_connection_hostname) else [])
  1710. }}
  1711. matrix_sms_bridge_container_network: "{{ matrix_addons_container_network }}"
  1712. matrix_sms_bridge_container_additional_networks_auto: |-
  1713. {{
  1714. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1715. }}
  1716. matrix_sms_bridge_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'sms.as.token', rounds=655555) | to_uuid }}"
  1717. matrix_sms_bridge_homeserver_hostname: "{{ (matrix_homeserver_container_client_api_endpoint | split(':'))[0] }}"
  1718. matrix_sms_bridge_homeserver_port: "{{ (matrix_homeserver_container_client_api_endpoint | split(':'))[1] }}"
  1719. matrix_sms_bridge_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'sms.hs.token', rounds=655555) | to_uuid }}"
  1720. ######################################################################
  1721. #
  1722. # /matrix-sms-bridge
  1723. #
  1724. ######################################################################
  1725. ######################################################################
  1726. #
  1727. # matrix-bridge-heisenbridge
  1728. #
  1729. ######################################################################
  1730. # We don't enable bridges by default.
  1731. matrix_heisenbridge_enabled: false
  1732. matrix_heisenbridge_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  1733. matrix_heisenbridge_systemd_required_services_list_auto: |
  1734. {{
  1735. matrix_addons_homeserver_systemd_services_list
  1736. }}
  1737. matrix_heisenbridge_container_network: "{{ matrix_addons_container_network }}"
  1738. matrix_heisenbridge_container_additional_networks_auto: |-
  1739. {{
  1740. (
  1741. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1742. +
  1743. [matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_heisenbridge_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else []
  1744. ) | unique
  1745. }}
  1746. matrix_heisenbridge_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1747. matrix_heisenbridge_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1748. matrix_heisenbridge_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1749. matrix_heisenbridge_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1750. matrix_heisenbridge_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'heisen.as.tok', rounds=655555) | to_uuid }}"
  1751. matrix_heisenbridge_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'heisen.hs.tok', rounds=655555) | to_uuid }}"
  1752. matrix_heisenbridge_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  1753. ######################################################################
  1754. #
  1755. # /matrix-bridge-heisenbridge
  1756. #
  1757. ######################################################################
  1758. ######################################################################
  1759. #
  1760. # matrix-bridge-hookshot
  1761. #
  1762. ######################################################################
  1763. # We don't enable bridges by default.
  1764. matrix_hookshot_enabled: false
  1765. matrix_hookshot_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1766. matrix_hookshot_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'hookshot.as.tok', rounds=655555) | to_uuid }}"
  1767. matrix_hookshot_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'hookshot.hs.tok', rounds=655555) | to_uuid }}"
  1768. matrix_hookshot_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1769. matrix_hookshot_systemd_wanted_services_list: |
  1770. {{
  1771. matrix_addons_homeserver_systemd_services_list
  1772. +
  1773. ([(redis_identifier + '.service')] if redis_enabled and matrix_hookshot_cache_redis_host == redis_identifier else [])
  1774. +
  1775. ([(keydb_identifier + '.service')] if keydb_enabled and matrix_hookshot_cache_redis_host == keydb_identifier else [])
  1776. +
  1777. ([(valkey_identifier + '.service')] if valkey_enabled and matrix_hookshot_cache_redis_host == valkey_identifier else [])
  1778. }}
  1779. # Hookshot's experimental encryption feature (and possibly others) may benefit from Redis, if available.
  1780. # We only connect to Redis if encryption is enabled (not for everyone who has Redis enabled),
  1781. # because connectivity is still potentially troublesome and is to be investigated.
  1782. matrix_hookshot_cache_redis_host: "{{ valkey_identifier if valkey_enabled else (redis_identifier if redis_enabled else (keydb_identifier if keydb_enabled else '')) }}"
  1783. matrix_hookshot_container_network: "{{ matrix_addons_container_network }}"
  1784. matrix_hookshot_container_additional_networks_auto: |
  1785. {{
  1786. (
  1787. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1788. +
  1789. ([redis_container_network] if redis_enabled and matrix_hookshot_cache_redis_host == redis_identifier else [])
  1790. +
  1791. ([keydb_container_network] if keydb_enabled and matrix_hookshot_cache_redis_host == keydb_identifier else [])
  1792. +
  1793. ([valkey_container_network] if valkey_enabled and matrix_hookshot_cache_redis_host == valkey_identifier else [])
  1794. +
  1795. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_hookshot_container_labels_traefik_enabled else [])
  1796. ) | unique
  1797. }}
  1798. matrix_hookshot_container_http_host_bind_ports_defaultmapping:
  1799. - "{{ matrix_playbook_service_host_bind_interface_prefix }}{{ matrix_hookshot_appservice_port }}:{{ matrix_hookshot_appservice_port }}"
  1800. - "{{ matrix_playbook_service_host_bind_interface_prefix }}{{ matrix_hookshot_metrics_port }}:{{ matrix_hookshot_metrics_port }}"
  1801. - "{{ matrix_playbook_service_host_bind_interface_prefix }}{{ matrix_hookshot_webhook_port }}:{{ matrix_hookshot_webhook_port }}"
  1802. - "{{ matrix_playbook_service_host_bind_interface_prefix }}{{ matrix_hookshot_provisioning_port }}:{{ matrix_hookshot_provisioning_port }}"
  1803. matrix_hookshot_container_http_host_bind_ports: "{{ matrix_hookshot_container_http_host_bind_ports_defaultmapping if matrix_playbook_service_host_bind_interface_prefix else [] }}"
  1804. matrix_hookshot_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1805. matrix_hookshot_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1806. matrix_hookshot_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1807. matrix_hookshot_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1808. matrix_hookshot_provisioning_enabled: "{{ matrix_hookshot_provisioning_secret and matrix_dimension_enabled }}"
  1809. matrix_hookshot_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  1810. matrix_hookshot_metrics_proxying_enabled: "{{ matrix_hookshot_metrics_enabled and matrix_metrics_exposure_enabled }}"
  1811. matrix_hookshot_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  1812. matrix_hookshot_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/hookshot"
  1813. matrix_hookshot_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  1814. matrix_hookshot_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  1815. matrix_hookshot_public_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  1816. matrix_hookshot_public_hostname: "{{ matrix_server_fqn_matrix }}"
  1817. ######################################################################
  1818. #
  1819. # /matrix-bridge-hookshot
  1820. #
  1821. ######################################################################
  1822. ######################################################################
  1823. #
  1824. # matrix-bridge-mx-puppet-slack
  1825. #
  1826. ######################################################################
  1827. # We don't enable bridges by default.
  1828. matrix_mx_puppet_slack_enabled: false
  1829. matrix_mx_puppet_slack_hostname: "{{ matrix_server_fqn_matrix }}"
  1830. matrix_mx_puppet_slack_systemd_required_services_list_auto: |
  1831. {{
  1832. matrix_addons_homeserver_systemd_services_list
  1833. +
  1834. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_slack_database_hostname == postgres_connection_hostname) else [])
  1835. }}
  1836. matrix_mx_puppet_slack_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  1837. matrix_mx_puppet_slack_container_network: "{{ matrix_addons_container_network }}"
  1838. matrix_mx_puppet_slack_container_additional_networks_auto: |-
  1839. {{
  1840. (
  1841. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1842. +
  1843. ([postgres_container_network] if (postgres_enabled and matrix_mx_puppet_slack_database_hostname == postgres_connection_hostname and matrix_mx_puppet_slack_container_network != postgres_container_network) else [])
  1844. +
  1845. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mx_puppet_slack_container_labels_traefik_enabled) else [])
  1846. ) | unique
  1847. }}
  1848. matrix_mx_puppet_slack_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1849. matrix_mx_puppet_slack_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1850. matrix_mx_puppet_slack_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1851. matrix_mx_puppet_slack_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1852. matrix_mx_puppet_slack_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxslk.as.tok', rounds=655555) | to_uuid }}"
  1853. matrix_mx_puppet_slack_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1854. matrix_mx_puppet_slack_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxslk.hs.tok', rounds=655555) | to_uuid }}"
  1855. matrix_mx_puppet_slack_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1856. matrix_mx_puppet_slack_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
  1857. # Postgres is the default, except if not using internal Postgres server
  1858. matrix_mx_puppet_slack_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1859. matrix_mx_puppet_slack_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1860. matrix_mx_puppet_slack_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.slack.db', rounds=655555) | to_uuid }}"
  1861. ######################################################################
  1862. #
  1863. # /matrix-bridge-mx-puppet-slack
  1864. #
  1865. ######################################################################
  1866. ######################################################################
  1867. #
  1868. # matrix-bridge-mx-puppet-twitter
  1869. #
  1870. ######################################################################
  1871. # We don't enable bridges by default.
  1872. matrix_mx_puppet_twitter_enabled: false
  1873. matrix_mx_puppet_twitter_hostname: "{{ matrix_server_fqn_matrix }}"
  1874. matrix_mx_puppet_twitter_systemd_required_services_list_auto: |
  1875. {{
  1876. matrix_addons_homeserver_systemd_services_list
  1877. +
  1878. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_twitter_database_hostname == postgres_connection_hostname) else [])
  1879. }}
  1880. matrix_mx_puppet_twitter_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  1881. matrix_mx_puppet_twitter_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '' ~ matrix_mx_puppet_twitter_appservice_port) if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  1882. matrix_mx_puppet_twitter_container_network: "{{ matrix_addons_container_network }}"
  1883. matrix_mx_puppet_twitter_container_additional_networks_auto: |-
  1884. {{
  1885. (
  1886. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1887. +
  1888. ([postgres_container_network] if (postgres_enabled and matrix_mx_puppet_twitter_database_hostname == postgres_connection_hostname and matrix_mx_puppet_twitter_container_network != postgres_container_network) else [])
  1889. +
  1890. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_mx_puppet_twitter_container_labels_traefik_enabled) else [])
  1891. ) | unique
  1892. }}
  1893. matrix_mx_puppet_twitter_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  1894. matrix_mx_puppet_twitter_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  1895. matrix_mx_puppet_twitter_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  1896. matrix_mx_puppet_twitter_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  1897. matrix_mx_puppet_twitter_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxtwt.as.tok', rounds=655555) | to_uuid }}"
  1898. matrix_mx_puppet_twitter_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1899. matrix_mx_puppet_twitter_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxtwt.hs.tok', rounds=655555) | to_uuid }}"
  1900. matrix_mx_puppet_twitter_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1901. matrix_mx_puppet_twitter_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
  1902. # Postgres is the default, except if not using internal Postgres server
  1903. matrix_mx_puppet_twitter_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1904. matrix_mx_puppet_twitter_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1905. matrix_mx_puppet_twitter_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.twitter.db', rounds=655555) | to_uuid }}"
  1906. ######################################################################
  1907. #
  1908. # /matrix-bridge-mx-puppet-twitter
  1909. #
  1910. ######################################################################
  1911. ######################################################################
  1912. #
  1913. # matrix-bridge-mx-puppet-instagram
  1914. #
  1915. ######################################################################
  1916. # We don't enable bridges by default.
  1917. matrix_mx_puppet_instagram_enabled: false
  1918. matrix_mx_puppet_instagram_systemd_required_services_list_auto: |
  1919. {{
  1920. matrix_addons_homeserver_systemd_services_list
  1921. +
  1922. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_instagram_database_hostname == postgres_connection_hostname) else [])
  1923. }}
  1924. matrix_mx_puppet_instagram_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  1925. matrix_mx_puppet_instagram_container_network: "{{ matrix_addons_container_network }}"
  1926. matrix_mx_puppet_instagram_container_additional_networks_auto: |-
  1927. {{
  1928. (
  1929. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1930. +
  1931. ([postgres_container_network] if (postgres_enabled and matrix_mx_puppet_instagram_database_hostname == postgres_connection_hostname and matrix_mx_puppet_instagram_container_network != postgres_container_network) else [])
  1932. ) | unique
  1933. }}
  1934. matrix_mx_puppet_instagram_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxig.as.tok', rounds=655555) | to_uuid }}"
  1935. matrix_mx_puppet_instagram_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1936. matrix_mx_puppet_instagram_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxig.hs.tok', rounds=655555) | to_uuid }}"
  1937. matrix_mx_puppet_instagram_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1938. matrix_mx_puppet_instagram_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
  1939. # Postgres is the default, except if not using internal Postgres server
  1940. matrix_mx_puppet_instagram_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1941. matrix_mx_puppet_instagram_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1942. matrix_mx_puppet_instagram_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.ig.db', rounds=655555) | to_uuid }}"
  1943. ######################################################################
  1944. #
  1945. # /matrix-bridge-mx-puppet-instagram
  1946. #
  1947. ######################################################################
  1948. ######################################################################
  1949. #
  1950. # matrix-bridge-mx-puppet-discord
  1951. #
  1952. ######################################################################
  1953. # We don't enable bridges by default.
  1954. matrix_mx_puppet_discord_enabled: false
  1955. matrix_mx_puppet_discord_systemd_required_services_list_auto: |
  1956. {{
  1957. matrix_addons_homeserver_systemd_services_list
  1958. +
  1959. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_discord_database_hostname == postgres_connection_hostname) else [])
  1960. }}
  1961. matrix_mx_puppet_discord_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  1962. matrix_mx_puppet_discord_container_network: "{{ matrix_addons_container_network }}"
  1963. matrix_mx_puppet_discord_container_additional_networks_auto: |-
  1964. {{
  1965. (
  1966. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  1967. +
  1968. ([postgres_container_network] if (postgres_enabled and matrix_mx_puppet_discord_database_hostname == postgres_connection_hostname and matrix_mx_puppet_discord_container_network != postgres_container_network) else [])
  1969. ) | unique
  1970. }}
  1971. matrix_mx_puppet_discord_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxdsc.as.tok', rounds=655555) | to_uuid }}"
  1972. matrix_mx_puppet_discord_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  1973. matrix_mx_puppet_discord_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxdsc.hs.tok', rounds=655555) | to_uuid }}"
  1974. matrix_mx_puppet_discord_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  1975. matrix_mx_puppet_discord_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
  1976. # Postgres is the default, except if not using internal Postgres server
  1977. matrix_mx_puppet_discord_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  1978. matrix_mx_puppet_discord_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  1979. matrix_mx_puppet_discord_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.dsc.db', rounds=655555) | to_uuid }}"
  1980. ######################################################################
  1981. #
  1982. # /matrix-bridge-mx-puppet-discord
  1983. #
  1984. ######################################################################
  1985. ######################################################################
  1986. #
  1987. # matrix-bridge-mx-puppet-steam
  1988. #
  1989. ######################################################################
  1990. # We don't enable bridges by default.
  1991. matrix_mx_puppet_steam_enabled: false
  1992. matrix_mx_puppet_steam_systemd_required_services_list_auto: |
  1993. {{
  1994. matrix_addons_homeserver_systemd_services_list
  1995. +
  1996. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_steam_database_hostname == postgres_connection_hostname) else [])
  1997. }}
  1998. matrix_mx_puppet_steam_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  1999. matrix_mx_puppet_steam_container_network: "{{ matrix_addons_container_network }}"
  2000. matrix_mx_puppet_steam_container_additional_networks_auto: |-
  2001. {{
  2002. (
  2003. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2004. +
  2005. ([postgres_container_network] if (postgres_enabled and matrix_mx_puppet_steam_database_hostname == postgres_connection_hostname and matrix_mx_puppet_steam_container_network != postgres_container_network) else [])
  2006. ) | unique
  2007. }}
  2008. matrix_mx_puppet_steam_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxste.as.tok', rounds=655555) | to_uuid }}"
  2009. matrix_mx_puppet_steam_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  2010. matrix_mx_puppet_steam_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxste.hs.tok', rounds=655555) | to_uuid }}"
  2011. matrix_mx_puppet_steam_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  2012. matrix_mx_puppet_steam_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
  2013. # Postgres is the default, except if not using internal Postgres server
  2014. matrix_mx_puppet_steam_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2015. matrix_mx_puppet_steam_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2016. matrix_mx_puppet_steam_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.steam.db', rounds=655555) | to_uuid }}"
  2017. ######################################################################
  2018. #
  2019. # /matrix-bridge-mx-puppet-steam
  2020. #
  2021. ######################################################################
  2022. ######################################################################
  2023. #
  2024. # matrix-bridge-mx-puppet-groupme
  2025. #
  2026. ######################################################################
  2027. # We don't enable bridges by default.
  2028. matrix_mx_puppet_groupme_enabled: false
  2029. matrix_mx_puppet_groupme_systemd_required_services_list_auto: |
  2030. {{
  2031. matrix_addons_homeserver_systemd_services_list
  2032. +
  2033. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_groupme_database_hostname == postgres_connection_hostname) else [])
  2034. }}
  2035. matrix_mx_puppet_groupme_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  2036. matrix_mx_puppet_groupme_container_network: "{{ matrix_addons_container_network }}"
  2037. matrix_mx_puppet_groupme_container_additional_networks_auto: |-
  2038. {{
  2039. (
  2040. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2041. +
  2042. ([postgres_container_network] if (postgres_enabled and matrix_mx_puppet_groupme_database_hostname == postgres_connection_hostname and matrix_mx_puppet_groupme_container_network != postgres_container_network) else [])
  2043. ) | unique
  2044. }}
  2045. matrix_mx_puppet_groupme_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxgro.as.tok', rounds=655555) | to_uuid }}"
  2046. matrix_mx_puppet_groupme_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
  2047. matrix_mx_puppet_groupme_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxgro.hs.tok', rounds=655555) | to_uuid }}"
  2048. matrix_mx_puppet_groupme_login_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret if matrix_synapse_ext_password_provider_shared_secret_auth_enabled else '' }}"
  2049. matrix_mx_puppet_groupme_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
  2050. # Postgres is the default, except if not using internal Postgres server
  2051. matrix_mx_puppet_groupme_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2052. matrix_mx_puppet_groupme_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2053. matrix_mx_puppet_groupme_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.groupme.db', rounds=655555) | to_uuid }}"
  2054. ######################################################################
  2055. #
  2056. # /matrix-bridge-mx-puppet-groupme
  2057. #
  2058. ######################################################################
  2059. ######################################################################
  2060. #
  2061. # matrix-bridge-postmoogle
  2062. #
  2063. ######################################################################
  2064. # We don't enable bridges by default.
  2065. matrix_postmoogle_enabled: false
  2066. matrix_postmoogle_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2067. matrix_postmoogle_ssl_path: |-
  2068. {{
  2069. {
  2070. 'playbook-managed-traefik': (traefik_certs_dumper_dumped_certificates_dir_path if traefik_certs_dumper_enabled else ''),
  2071. 'other-traefik-container': (traefik_certs_dumper_dumped_certificates_dir_path if traefik_certs_dumper_enabled else ''),
  2072. 'none': '',
  2073. }[matrix_playbook_reverse_proxy_type]
  2074. }}
  2075. matrix_playbook_bridge_postmoogle_traefik_tls_cert: "{% for domain in matrix_postmoogle_domains %}/ssl/{{ domain }}/certificate.crt {% endfor %}"
  2076. matrix_playbook_bridge_postmoogle_traefik_key: "{% for domain in matrix_postmoogle_domains %}/ssl/{{ domain }}/privatekey.key {% endfor %}"
  2077. matrix_postmoogle_tls_cert: |-
  2078. {{
  2079. {
  2080. 'playbook-managed-traefik': (matrix_playbook_bridge_postmoogle_traefik_tls_cert if traefik_certs_dumper_enabled else ''),
  2081. 'other-traefik-container': (matrix_playbook_bridge_postmoogle_traefik_tls_cert if traefik_certs_dumper_enabled else ''),
  2082. 'none': '',
  2083. }[matrix_playbook_reverse_proxy_type]
  2084. }}
  2085. matrix_postmoogle_tls_key: |-
  2086. {{
  2087. {
  2088. 'playbook-managed-traefik': (matrix_playbook_bridge_postmoogle_traefik_key if traefik_certs_dumper_enabled else ''),
  2089. 'other-traefik-container': (matrix_playbook_bridge_postmoogle_traefik_key if traefik_certs_dumper_enabled else ''),
  2090. 'none': '',
  2091. }[matrix_playbook_reverse_proxy_type]
  2092. }}
  2093. matrix_playbook_bridge_postmoogle_traefik_certs_dumper_waiter_services: "{% for domain in matrix_postmoogle_domains %}{{ traefik_certs_dumper_identifier }}-wait-for-domain@{{ domain }}.service {% endfor %}"
  2094. matrix_postmoogle_systemd_required_services_list_auto: |
  2095. {{
  2096. matrix_addons_homeserver_systemd_services_list
  2097. +
  2098. ([postgres_identifier ~ '.service'] if postgres_enabled and matrix_postmoogle_database_hostname == matrix_postmoogle_database_hostname else [])
  2099. +
  2100. (matrix_playbook_bridge_postmoogle_traefik_certs_dumper_waiter_services | trim | split(' ') if matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] and traefik_certs_dumper_enabled else [])
  2101. }}
  2102. # Postgres is the default, except if not using internal Postgres server
  2103. matrix_postmoogle_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2104. matrix_postmoogle_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2105. matrix_postmoogle_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'postmoogle.db', rounds=655555) | to_uuid }}"
  2106. matrix_postmoogle_homeserver: "{{ matrix_addons_homeserver_client_api_url }}"
  2107. matrix_postmoogle_container_network: "{{ matrix_addons_container_network }}"
  2108. matrix_postmoogle_container_additional_networks_auto: |-
  2109. {{
  2110. (
  2111. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2112. +
  2113. ([postgres_container_network] if postgres_enabled and matrix_bot_matrix_reminder_bot_database_hostname == postgres_connection_hostname else [])
  2114. ) | unique
  2115. }}
  2116. ######################################################################
  2117. #
  2118. # /matrix-bridge-postmoogle
  2119. #
  2120. ######################################################################
  2121. ######################################################################
  2122. #
  2123. # matrix-bot-matrix-reminder-bot
  2124. #
  2125. ######################################################################
  2126. # We don't enable bots by default.
  2127. matrix_bot_matrix_reminder_bot_enabled: false
  2128. matrix_bot_matrix_reminder_bot_systemd_required_services_list_auto: |
  2129. {{
  2130. matrix_addons_homeserver_systemd_services_list
  2131. +
  2132. ([postgres_identifier ~ '.service'] if postgres_enabled and matrix_bot_matrix_reminder_bot_database_hostname == postgres_connection_hostname else [])
  2133. }}
  2134. matrix_bot_matrix_reminder_bot_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2135. matrix_bot_matrix_reminder_bot_container_network: "{{ matrix_addons_container_network }}"
  2136. matrix_bot_matrix_reminder_bot_container_additional_networks_auto: |-
  2137. {{
  2138. (
  2139. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2140. +
  2141. ([postgres_container_network] if postgres_enabled and matrix_bot_matrix_reminder_bot_database_hostname == postgres_connection_hostname else [])
  2142. ) | unique
  2143. }}
  2144. matrix_bot_matrix_reminder_bot_matrix_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2145. # Postgres is the default, except if not using internal Postgres server
  2146. matrix_bot_matrix_reminder_bot_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2147. matrix_bot_matrix_reminder_bot_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2148. matrix_bot_matrix_reminder_bot_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'reminder.bot.db', rounds=655555) | to_uuid }}"
  2149. matrix_bot_matrix_reminder_bot_allowlist_enabled: true
  2150. matrix_bot_matrix_reminder_bot_allowlist_regexes_auto:
  2151. - "@[a-z0-9-_.]+:{{ matrix_domain }}"
  2152. ######################################################################
  2153. #
  2154. # /matrix-bot-matrix-reminder-bot
  2155. #
  2156. ######################################################################
  2157. ######################################################################
  2158. #
  2159. # matrix-bot-matrix-registration-bot
  2160. #
  2161. ######################################################################
  2162. # We don't enable bots by default.
  2163. matrix_bot_matrix_registration_bot_enabled: false
  2164. matrix_bot_matrix_registration_bot_systemd_required_services_list_auto: |
  2165. {{
  2166. matrix_addons_homeserver_systemd_services_list
  2167. }}
  2168. matrix_bot_matrix_registration_bot_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  2169. matrix_bot_matrix_registration_bot_container_network: "{{ matrix_addons_container_network }}"
  2170. matrix_bot_matrix_registration_bot_container_additional_networks_auto: |-
  2171. {{
  2172. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2173. }}
  2174. matrix_bot_matrix_registration_bot_matrix_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2175. ######################################################################
  2176. #
  2177. # /matrix-bot-matrix-registration-bot
  2178. #
  2179. ######################################################################
  2180. ######################################################################
  2181. #
  2182. # matrix-bot-maubot
  2183. #
  2184. ######################################################################
  2185. # We don't enable bots by default.
  2186. matrix_bot_maubot_enabled: false
  2187. matrix_bot_maubot_systemd_required_services_list_auto: |
  2188. {{
  2189. matrix_addons_homeserver_systemd_services_list
  2190. +
  2191. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_bot_maubot_database_hostname == postgres_connection_hostname) else [])
  2192. }}
  2193. matrix_bot_maubot_hostname: "{{ matrix_server_fqn_matrix }}"
  2194. matrix_bot_maubot_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2195. matrix_bot_maubot_homeserver_secret: |-
  2196. {{
  2197. {
  2198. 'synapse': matrix_synapse_registration_shared_secret | default(''),
  2199. 'dendrite': matrix_dendrite_client_api_registration_shared_secret | default(''),
  2200. }[matrix_homeserver_implementation] | default('')
  2201. }}
  2202. matrix_bot_maubot_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  2203. matrix_bot_maubot_container_management_interface_http_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '' ~ matrix_bot_maubot_server_port | string) if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2204. matrix_bot_maubot_container_network: "{{ matrix_addons_container_network }}"
  2205. matrix_bot_maubot_container_additional_networks_auto: |-
  2206. {{
  2207. (
  2208. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2209. +
  2210. ([postgres_container_network] if (postgres_enabled and matrix_bot_maubot_database_hostname == postgres_connection_hostname and matrix_bot_maubot_container_network != postgres_container_network) else [])
  2211. +
  2212. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_bot_maubot_container_labels_traefik_enabled else [])
  2213. ) | unique
  2214. }}
  2215. matrix_bot_maubot_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  2216. matrix_bot_maubot_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2217. matrix_bot_maubot_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2218. matrix_bot_maubot_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2219. matrix_bot_maubot_container_labels_management_hostname: "{{ matrix_server_fqn_matrix }}"
  2220. # Postgres is the default, except if not using internal Postgres server
  2221. matrix_bot_maubot_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2222. matrix_bot_maubot_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2223. matrix_bot_maubot_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mxpup.dsc.db', rounds=655555) | to_uuid }}"
  2224. ######################################################################
  2225. #
  2226. # /matrix-bot-maubot
  2227. #
  2228. ######################################################################
  2229. ######################################################################
  2230. #
  2231. # matrix-bot-honoroit
  2232. #
  2233. ######################################################################
  2234. # We don't enable bots by default.
  2235. matrix_bot_honoroit_enabled: false
  2236. matrix_bot_honoroit_hostname: "{{ matrix_server_fqn_matrix }}"
  2237. matrix_bot_honoroit_path_prefix: /honoroit
  2238. matrix_bot_honoroit_systemd_required_services_list_auto: |
  2239. {{
  2240. matrix_addons_homeserver_systemd_services_list
  2241. +
  2242. ([postgres_identifier ~ '.service'] if postgres_enabled and matrix_bot_honoroit_database_hostname == postgres_connection_hostname else [])
  2243. }}
  2244. matrix_bot_honoroit_container_network: "{{ matrix_addons_container_network }}"
  2245. matrix_bot_honoroit_container_additional_networks: |
  2246. {{
  2247. (
  2248. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2249. +
  2250. ([postgres_container_network] if (postgres_enabled and matrix_bot_honoroit_database_hostname == postgres_connection_hostname and matrix_bot_honoroit_container_network != postgres_container_network) else [])
  2251. +
  2252. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_bot_honoroit_container_labels_traefik_enabled else [])
  2253. ) | unique
  2254. }}
  2255. matrix_bot_honoroit_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  2256. matrix_bot_honoroit_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2257. matrix_bot_honoroit_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2258. matrix_bot_honoroit_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2259. # For consistency with other things hosted at the Matrix FQN, we adjust the metrics endpoint
  2260. # so that metrics would be served at something like `/metrics/SERVICE_NAME`, and not at the default path for the role (`PREFIX/metrics`).
  2261. matrix_bot_honoroit_container_labels_traefik_metrics_path: "{{ matrix_metrics_exposure_path_prefix }}/honoroit"
  2262. matrix_bot_honoroit_homeserver: "{{ matrix_addons_homeserver_client_api_url }}"
  2263. # Postgres is the default, except if not using internal Postgres server
  2264. matrix_bot_honoroit_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2265. matrix_bot_honoroit_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2266. matrix_bot_honoroit_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'honoroit.bot.db', rounds=655555) | to_uuid }}"
  2267. matrix_bot_honoroit_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2268. ######################################################################
  2269. #
  2270. # /matrix-bot-honoroit
  2271. #
  2272. ######################################################################
  2273. ######################################################################
  2274. #
  2275. # matrix-bot-buscarron
  2276. #
  2277. ######################################################################
  2278. # We don't enable bots by default.
  2279. matrix_bot_buscarron_enabled: false
  2280. matrix_bot_buscarron_hostname: "{{ matrix_server_fqn_buscarron }}"
  2281. matrix_bot_buscarron_systemd_required_services_list_auto: |
  2282. {{
  2283. matrix_addons_homeserver_systemd_services_list
  2284. +
  2285. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_bot_buscarron_database_hostname == postgres_connection_hostname) else [])
  2286. }}
  2287. matrix_bot_buscarron_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2288. matrix_bot_buscarron_container_network: "{{ matrix_addons_container_network }}"
  2289. matrix_bot_buscarron_container_additional_networks_auto: |-
  2290. {{
  2291. (
  2292. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2293. +
  2294. ([postgres_container_network] if (postgres_enabled and matrix_bot_buscarron_database_hostname == postgres_connection_hostname and matrix_bot_buscarron_container_network != postgres_container_network) else [])
  2295. +
  2296. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_bot_buscarron_container_labels_traefik_enabled else [])
  2297. ) | unique
  2298. }}
  2299. matrix_bot_buscarron_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  2300. matrix_bot_buscarron_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2301. matrix_bot_buscarron_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2302. matrix_bot_buscarron_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2303. matrix_bot_buscarron_homeserver: "{{ matrix_addons_homeserver_client_api_url }}"
  2304. # Postgres is the default, except if not using internal Postgres server
  2305. matrix_bot_buscarron_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2306. matrix_bot_buscarron_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2307. matrix_bot_buscarron_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'buscarron.bot.db', rounds=655555) | to_uuid }}"
  2308. ######################################################################
  2309. #
  2310. # /matrix-bot-buscarron
  2311. #
  2312. ######################################################################
  2313. ######################################################################
  2314. #
  2315. # matrix-bot-baibot
  2316. #
  2317. ######################################################################
  2318. # We don't enable bots by default.
  2319. matrix_bot_baibot_enabled: false
  2320. matrix_bot_baibot_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2321. matrix_bot_baibot_systemd_required_services_list_auto: |
  2322. {{
  2323. matrix_addons_homeserver_systemd_services_list
  2324. }}
  2325. matrix_bot_baibot_config_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2326. matrix_bot_baibot_container_network: "{{ matrix_addons_container_network }}"
  2327. matrix_bot_baibot_container_additional_networks_auto: |-
  2328. {{
  2329. (
  2330. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2331. ) | unique
  2332. }}
  2333. ######################################################################
  2334. #
  2335. # /matrix-bot-baibot
  2336. #
  2337. ######################################################################
  2338. ######################################################################
  2339. #
  2340. # matrix-bot-chatgpt
  2341. #
  2342. ######################################################################
  2343. # We don't enable bots by default.
  2344. matrix_bot_chatgpt_enabled: false
  2345. matrix_bot_chatgpt_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2346. matrix_bot_chatgpt_container_network: "{{ matrix_addons_container_network }}"
  2347. matrix_bot_chatgpt_container_additional_networks_auto: "{{ [] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network] }}"
  2348. matrix_bot_chatgpt_matrix_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2349. matrix_bot_chatgpt_systemd_required_services_list_auto: "{{ matrix_addons_homeserver_systemd_services_list }}"
  2350. ######################################################################
  2351. #
  2352. # /matrix-bot-chatgpt
  2353. #
  2354. ######################################################################
  2355. ######################################################################
  2356. #
  2357. # matrix-bot-go-neb
  2358. #
  2359. ######################################################################
  2360. # We don't enable bots by default.
  2361. matrix_bot_go_neb_enabled: false
  2362. matrix_bot_go_neb_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  2363. matrix_bot_go_neb_hostname: "{{ matrix_server_fqn_bot_go_neb }}"
  2364. matrix_bot_go_neb_systemd_required_services_list_auto: |
  2365. {{
  2366. matrix_addons_homeserver_systemd_services_list
  2367. }}
  2368. matrix_bot_go_neb_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '4050') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2369. matrix_bot_go_neb_container_network: "{{ matrix_addons_container_network }}"
  2370. matrix_bot_go_neb_container_additional_networks: |
  2371. {{
  2372. (
  2373. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2374. +
  2375. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and matrix_bot_go_neb_container_labels_traefik_enabled else [])
  2376. ) | unique
  2377. }}
  2378. matrix_bot_go_neb_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  2379. matrix_bot_go_neb_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2380. matrix_bot_go_neb_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2381. matrix_bot_go_neb_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2382. ######################################################################
  2383. #
  2384. # /matrix-bot-go-neb
  2385. #
  2386. ######################################################################
  2387. ######################################################################
  2388. #
  2389. # matrix-bot-mjolnir
  2390. #
  2391. ######################################################################
  2392. # We don't enable bots by default.
  2393. matrix_bot_mjolnir_enabled: false
  2394. matrix_bot_mjolnir_systemd_required_services_list_auto: |
  2395. {{
  2396. matrix_addons_homeserver_systemd_services_list
  2397. +
  2398. (['matrix-pantalaimon.service'] if matrix_bot_mjolnir_pantalaimon_use else [])
  2399. }}
  2400. matrix_bot_mjolnir_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  2401. matrix_bot_mjolnir_container_network: "{{ matrix_addons_container_network }}"
  2402. matrix_bot_mjolnir_container_additional_networks_auto: |-
  2403. {{
  2404. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2405. }}
  2406. matrix_bot_mjolnir_homeserver_url: "{{ 'http://matrix-pantalaimon:8009' if matrix_bot_mjolnir_pantalaimon_use else matrix_addons_homeserver_client_api_url }}"
  2407. matrix_bot_mjolnir_raw_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2408. ######################################################################
  2409. #
  2410. # /matrix-bot-mjolnir
  2411. #
  2412. ######################################################################
  2413. ######################################################################
  2414. #
  2415. # matrix-bot-draupnir
  2416. #
  2417. ######################################################################
  2418. # We don't enable bots by default.
  2419. matrix_bot_draupnir_enabled: false
  2420. matrix_bot_draupnir_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8769') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2421. matrix_bot_draupnir_systemd_required_services_list_auto: |
  2422. {{
  2423. matrix_addons_homeserver_systemd_services_list
  2424. +
  2425. (['matrix-pantalaimon.service'] if matrix_bot_draupnir_pantalaimon_use else [])
  2426. }}
  2427. matrix_bot_draupnir_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2428. matrix_bot_draupnir_container_network: "{{ matrix_addons_container_network }}"
  2429. matrix_bot_draupnir_container_additional_networks_auto: |-
  2430. {{
  2431. (
  2432. ([] if matrix_addons_homeserver_container_network == '' else
  2433. [matrix_addons_homeserver_container_network])
  2434. +
  2435. ([matrix_playbook_reverse_proxyable_services_additional_network] if
  2436. (matrix_playbook_reverse_proxyable_services_additional_network and matrix_bot_draupnir_container_labels_traefik_enabled) else [])
  2437. +
  2438. ([matrix_pantalaimon_container_network] if (matrix_bot_draupnir_pantalaimon_use and matrix_pantalaimon_container_network != matrix_bot_draupnir_container_network) else [])
  2439. ) | unique
  2440. }}
  2441. matrix_bot_draupnir_homeserver_url: "{{ 'http://matrix-pantalaimon:8009' if matrix_bot_draupnir_pantalaimon_use else matrix_addons_homeserver_client_api_url }}"
  2442. matrix_bot_draupnir_raw_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2443. matrix_bot_draupnir_container_labels_traefik_enabled: "{{ matrix_bot_draupnir_web_enabled and matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  2444. matrix_bot_draupnir_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2445. matrix_bot_draupnir_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2446. matrix_bot_draupnir_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2447. ######################################################################
  2448. #
  2449. # /matrix-bot-draupnir
  2450. #
  2451. ######################################################################
  2452. ######################################################################
  2453. #
  2454. # matrix-appservice-draupnir-for-all
  2455. #
  2456. ######################################################################
  2457. # We don't enable bots by default.
  2458. matrix_appservice_draupnir_for_all_enabled: false
  2459. matrix_appservice_draupnir_for_all_systemd_required_services_list_auto: |
  2460. {{
  2461. matrix_addons_homeserver_systemd_services_list
  2462. +
  2463. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_draupnir_for_all_database_hostname == postgres_connection_hostname) else [])
  2464. }}
  2465. matrix_appservice_draupnir_for_all_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  2466. matrix_appservice_draupnir_for_all_container_network: "{{ matrix_addons_container_network }}"
  2467. matrix_appservice_draupnir_for_all_container_additional_networks_auto: |-
  2468. {{
  2469. (
  2470. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2471. +
  2472. ([postgres_container_network] if (postgres_enabled and matrix_appservice_draupnir_for_all_database_hostname == postgres_connection_hostname and matrix_appservice_draupnir_for_all_container_network != postgres_container_network) else [])
  2473. ) | unique
  2474. }}
  2475. matrix_appservice_draupnir_for_all_appservice_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'd4a.as.token', rounds=655555) | to_uuid }}"
  2476. matrix_appservice_draupnir_for_all_homeserver_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'd4a.hs.token', rounds=655555) | to_uuid }}"
  2477. matrix_appservice_draupnir_for_all_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2478. matrix_appservice_draupnir_for_all_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.d4a.db', rounds=655555) | to_uuid }}"
  2479. ######################################################################
  2480. #
  2481. # /matrix-appservice-draupnir-for-all
  2482. #
  2483. ######################################################################
  2484. ######################################################################
  2485. #
  2486. # matrix-appservice-double-puppet
  2487. #
  2488. ######################################################################
  2489. matrix_appservice_double_puppet_enabled: false
  2490. matrix_appservice_double_puppet_registration_as_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'as.doub.pup', rounds=655555) | to_uuid }}"
  2491. matrix_appservice_double_puppet_registration_hs_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'hs.doub.pup', rounds=655555) | to_uuid }}"
  2492. ######################################################################
  2493. #
  2494. # /matrix-appservice-double-puppet
  2495. #
  2496. ######################################################################
  2497. ######################################################################
  2498. #
  2499. # matrix-pantalaimon
  2500. #
  2501. ######################################################################
  2502. matrix_pantalaimon_enabled: false
  2503. matrix_pantalaimon_systemd_required_services_list_auto: |
  2504. {{
  2505. matrix_addons_homeserver_systemd_services_list
  2506. }}
  2507. matrix_pantalaimon_container_network: "{{ matrix_homeserver_container_network }}"
  2508. matrix_pantalaimon_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  2509. matrix_pantalaimon_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2510. ######################################################################
  2511. #
  2512. # /matrix-pantalaimon
  2513. #
  2514. ######################################################################
  2515. ######################################################################
  2516. #
  2517. # etke/backup_borg
  2518. #
  2519. ######################################################################
  2520. backup_borg_enabled: false
  2521. backup_borg_identifier: matrix-backup-borg
  2522. backup_borg_retention_prefix: matrix-
  2523. backup_borg_storage_archive_name_format: matrix-{now:%Y-%m-%d-%H%M%S}
  2524. backup_borg_base_path: "{{ matrix_base_data_path }}/backup-borg"
  2525. backup_borg_username: "{{ matrix_user_username }}"
  2526. backup_borg_uid: "{{ matrix_user_uid }}"
  2527. backup_borg_gid: "{{ matrix_user_gid }}"
  2528. backup_borg_container_network: "{{ postgres_container_network if postgres_enabled else backup_borg_identifier }}"
  2529. backup_borg_postgresql_version_detection_postgres_role_name: "{{ 'galaxy/postgres' if postgres_enabled else '' }}"
  2530. backup_borg_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm32', 'arm64'] }}"
  2531. backup_borg_postgresql_enabled: "{{ postgres_enabled }}"
  2532. backup_borg_postgresql_databases_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2533. backup_borg_postgresql_databases_username: "{{ postgres_connection_username if postgres_enabled else '' }}"
  2534. backup_borg_postgresql_databases_password: "{{ postgres_connection_password if postgres_enabled else '' }}"
  2535. backup_borg_postgresql_databases_port: "{{ postgres_connection_port if postgres_enabled else 5432 }}"
  2536. backup_borg_postgresql_databases: "{{ postgres_managed_databases | map(attribute='name') if postgres_enabled else [] }}"
  2537. backup_borg_location_source_directories:
  2538. - "{{ matrix_base_data_path }}"
  2539. backup_borg_location_exclude_patterns: |
  2540. {{
  2541. ([matrix_synapse_media_store_path + '/local_thumbnails', matrix_synapse_media_store_path + '/remote_thumbnail', matrix_synapse_media_store_path + '/url_cache', matrix_synapse_media_store_path + '/url_cache_thumbnails'] if matrix_homeserver_implementation == 'synapse' else [])
  2542. +
  2543. ([postgres_data_path] if postgres_enabled else [])
  2544. }}
  2545. backup_borg_systemd_required_services_list: |
  2546. {{
  2547. [devture_systemd_docker_base_docker_service_name]
  2548. +
  2549. ([postgres_identifier ~ '.service'] if postgres_enabled else [])
  2550. }}
  2551. ######################################################################
  2552. #
  2553. # /etke/backup_borg
  2554. #
  2555. ######################################################################
  2556. ######################################################################
  2557. #
  2558. # matrix-cactus-comments
  2559. #
  2560. ######################################################################
  2561. matrix_cactus_comments_enabled: false
  2562. matrix_cactus_comments_systemd_required_services_list_auto: |
  2563. {{
  2564. matrix_addons_homeserver_systemd_services_list
  2565. }}
  2566. matrix_cactus_comments_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  2567. matrix_cactus_comments_container_network: "{{ matrix_addons_container_network }}"
  2568. matrix_cactus_comments_container_additional_networks_auto: |-
  2569. {{
  2570. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2571. }}
  2572. matrix_cactus_comments_as_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'cactus.as.token', rounds=655555) | to_uuid }}"
  2573. matrix_cactus_comments_hs_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'cactus.hs.token', rounds=655555) | to_uuid }}"
  2574. matrix_cactus_comments_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2575. ######################################################################
  2576. #
  2577. # /matrix-cactus-comments
  2578. #
  2579. ######################################################################
  2580. ######################################################################
  2581. #
  2582. # matrix-cactus-comments-client
  2583. #
  2584. ######################################################################
  2585. matrix_cactus_comments_client_enabled: "{{ matrix_cactus_comments_enabled }}"
  2586. matrix_cactus_comments_client_hostname: "{{ matrix_server_fqn_matrix }}"
  2587. matrix_cactus_comments_client_container_network: "{{ matrix_addons_container_network }}"
  2588. matrix_cactus_comments_client_container_additional_networks_auto: |-
  2589. {{
  2590. (
  2591. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_cactus_comments_client_container_labels_traefik_enabled) else [])
  2592. ) | unique
  2593. }}
  2594. matrix_cactus_comments_client_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  2595. matrix_cactus_comments_client_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2596. matrix_cactus_comments_client_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2597. matrix_cactus_comments_client_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2598. ######################################################################
  2599. #
  2600. # /matrix-cactus-comments-client
  2601. #
  2602. ######################################################################
  2603. ######################################################################
  2604. #
  2605. # matrix-corporal
  2606. #
  2607. ######################################################################
  2608. matrix_corporal_enabled: false
  2609. matrix_corporal_systemd_required_services_list_auto: |
  2610. {{
  2611. (['matrix-' + matrix_homeserver_implementation + '.service'])
  2612. }}
  2613. matrix_corporal_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm32', 'arm64'] }}"
  2614. matrix_corporal_container_http_gateway_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '41080') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2615. matrix_corporal_container_http_api_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '41081') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2616. matrix_corporal_container_network: matrix-corporal
  2617. matrix_corporal_container_additional_networks: |
  2618. {{
  2619. (
  2620. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  2621. +
  2622. ([matrix_homeserver_container_network] if matrix_corporal_container_network != matrix_homeserver_container_network else [])
  2623. ) | unique
  2624. }}
  2625. matrix_corporal_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  2626. matrix_corporal_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2627. matrix_corporal_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2628. matrix_corporal_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2629. matrix_corporal_matrix_homeserver_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  2630. matrix_corporal_matrix_homeserver_api_endpoint: "{{ matrix_homeserver_container_url }}"
  2631. matrix_corporal_matrix_auth_shared_secret: "{{ matrix_synapse_ext_password_provider_shared_secret_auth_shared_secret }}"
  2632. # This is only useful if there's REST auth provider to make use of it.
  2633. matrix_corporal_http_gateway_internal_rest_auth_enabled: "{{ matrix_synapse_ext_password_provider_rest_auth_enabled }}"
  2634. matrix_corporal_matrix_registration_shared_secret: "{{ matrix_synapse_registration_shared_secret }}"
  2635. ######################################################################
  2636. #
  2637. # /matrix-corporal
  2638. #
  2639. ######################################################################
  2640. ######################################################################
  2641. #
  2642. # matrix-rageshake
  2643. #
  2644. ######################################################################
  2645. # We don't enable rageshake by default.
  2646. matrix_rageshake_enabled: false
  2647. matrix_rageshake_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  2648. matrix_rageshake_hostname: "{{ matrix_server_fqn_rageshake }}"
  2649. matrix_rageshake_container_network: matrix-rageshake
  2650. matrix_rageshake_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [] }}"
  2651. matrix_rageshake_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9110') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2652. matrix_rageshake_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  2653. matrix_rageshake_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2654. matrix_rageshake_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2655. matrix_rageshake_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2656. ######################################################################
  2657. #
  2658. # /matrix-rageshake
  2659. #
  2660. ######################################################################
  2661. ######################################################################
  2662. #
  2663. # matrix-coturn
  2664. #
  2665. ######################################################################
  2666. matrix_coturn_enabled: true
  2667. matrix_coturn_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm32', 'arm64'] }}"
  2668. # We make the assumption that `ansible_host` points to an external IP address, which may not always be the case.
  2669. # Users are free to set `matrix_coturn_turn_external_ip_address` to an empty string
  2670. # to allow auto-detection (via an EchoIP service) to happen at runtime.
  2671. matrix_coturn_turn_external_ip_address: "{{ ansible_host }}"
  2672. matrix_coturn_turn_static_auth_secret: "{{ ('%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'coturn.sas', rounds=655555) | to_uuid) if matrix_coturn_authentication_method == 'auth-secret' else '' }}"
  2673. matrix_coturn_lt_cred_mech_username: "{{ ('%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'coturn.user', rounds=655555) | to_uuid) if matrix_coturn_authentication_method == 'lt-cred-mech' else '' }}"
  2674. matrix_coturn_lt_cred_mech_password: "{{ ('%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'coturn.pass', rounds=655555) | to_uuid) if matrix_coturn_authentication_method == 'lt-cred-mech' else '' }}"
  2675. matrix_coturn_tls_enabled: "{{ matrix_playbook_ssl_enabled }}"
  2676. matrix_coturn_tls_cert_path: |-
  2677. {{
  2678. {
  2679. 'playbook-managed-traefik': ('/certificate.crt' if traefik_certs_dumper_enabled else ''),
  2680. 'other-traefik-container': ('/certificate.crt' if traefik_certs_dumper_enabled else ''),
  2681. 'none': '',
  2682. }[matrix_playbook_reverse_proxy_type]
  2683. }}
  2684. matrix_coturn_tls_key_path: |-
  2685. {{
  2686. {
  2687. 'playbook-managed-traefik': ('/privatekey.key' if traefik_certs_dumper_enabled else ''),
  2688. 'other-traefik-container': ('/privatekey.key' if traefik_certs_dumper_enabled else ''),
  2689. 'none': '',
  2690. }[matrix_playbook_reverse_proxy_type]
  2691. }}
  2692. matrix_coturn_container_additional_volumes: |
  2693. {{
  2694. (
  2695. [
  2696. {
  2697. 'src': (traefik_certs_dumper_dumped_certificates_dir_path + '/' + matrix_server_fqn_matrix + '/certificate.crt'),
  2698. 'dst': '/certificate.crt',
  2699. 'options': 'ro',
  2700. },
  2701. {
  2702. 'src': (traefik_certs_dumper_dumped_certificates_dir_path + '/' + matrix_server_fqn_matrix + '/privatekey.key'),
  2703. 'dst': '/privatekey.key',
  2704. 'options': 'ro',
  2705. },
  2706. ] if (matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] and traefik_certs_dumper_enabled and matrix_coturn_tls_enabled and (matrix_coturn_tls_cert_path and matrix_coturn_tls_key_path)) else []
  2707. )
  2708. }}
  2709. matrix_coturn_systemd_required_services_list: |
  2710. {{
  2711. [devture_systemd_docker_base_docker_service_name]
  2712. +
  2713. ([traefik_certs_dumper_identifier + '-wait-for-domain@' + matrix_server_fqn_matrix + '.service'] if matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] and traefik_certs_dumper_enabled and matrix_coturn_tls_enabled else [])
  2714. }}
  2715. ######################################################################
  2716. #
  2717. # /matrix-coturn
  2718. #
  2719. ######################################################################
  2720. ######################################################################
  2721. #
  2722. # matrix-dimension
  2723. #
  2724. ######################################################################
  2725. matrix_dimension_enabled: false
  2726. matrix_dimension_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  2727. matrix_dimension_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  2728. matrix_dimension_hostname: "{{ matrix_server_fqn_dimension }}"
  2729. matrix_dimension_container_network: "{{ matrix_addons_container_network }}"
  2730. # Dimension is connected both to `matrix_addons_homeserver_container_network` and `matrix_homeserver_container_network`,
  2731. # because `matrix_dimension_homeserver_clientServerUrl` and `matrix_dimension_homeserver_federationUrl` are potentially
  2732. # going to different places.
  2733. matrix_dimension_container_additional_networks: |
  2734. {{
  2735. (
  2736. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2737. +
  2738. ([matrix_homeserver_container_network] if matrix_homeserver_container_network != matrix_dimension_container_network else [])
  2739. +
  2740. ([postgres_container_network] if (postgres_enabled and matrix_dimension_database_hostname == postgres_connection_hostname and postgres_container_network != matrix_dimension_container_network) else [])
  2741. +
  2742. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  2743. ) | unique
  2744. }}
  2745. matrix_dimension_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8184') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2746. matrix_dimension_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  2747. matrix_dimension_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2748. matrix_dimension_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2749. matrix_dimension_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2750. matrix_dimension_homeserver_clientServerUrl: "{{ matrix_addons_homeserver_client_api_url }}"
  2751. matrix_dimension_homeserver_federationUrl: "{{ matrix_homeserver_container_federation_url }}"
  2752. matrix_dimension_homeserver_mediaUrl: "{{ ('https' if matrix_playbook_ssl_enabled else 'http') }}://{{ matrix_server_fqn_matrix }}"
  2753. # Dimension depends both on `matrix_addons_homeserver_systemd_services_list` and on the homeserver service,
  2754. # because `matrix_dimension_homeserver_clientServerUrl` and `matrix_dimension_homeserver_federationUrl` are potentially
  2755. # going to different places.
  2756. matrix_dimension_systemd_required_services_list_auto: |
  2757. {{
  2758. (
  2759. matrix_addons_homeserver_systemd_services_list
  2760. +
  2761. ['matrix-' + matrix_homeserver_implementation + '.service']
  2762. +
  2763. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_dimension_database_hostname == postgres_connection_hostname) else [])
  2764. ) | unique
  2765. }}
  2766. # Postgres is the default, except if not using internal Postgres server
  2767. matrix_dimension_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  2768. matrix_dimension_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2769. matrix_dimension_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'dimension.db', rounds=655555) | to_uuid }}"
  2770. ######################################################################
  2771. #
  2772. # /matrix-dimension
  2773. #
  2774. ######################################################################
  2775. ######################################################################
  2776. #
  2777. # etke/etherpad
  2778. #
  2779. ######################################################################
  2780. etherpad_enabled: false
  2781. etherpad_identifier: matrix-etherpad
  2782. etherpad_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  2783. etherpad_base_path: "{{ matrix_base_data_path }}/etherpad"
  2784. etherpad_framing_enabled: "{{ matrix_dimension_enabled or jitsi_enabled }}"
  2785. etherpad_hostname: "{{ matrix_server_fqn_etherpad }}"
  2786. etherpad_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  2787. etherpad_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9001') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2788. etherpad_container_network: "{{ matrix_addons_container_network }}"
  2789. etherpad_container_additional_networks: |
  2790. {{
  2791. (
  2792. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  2793. +
  2794. ([postgres_container_network] if postgres_enabled and postgres_container_network != etherpad_container_network else [])
  2795. ) | unique
  2796. }}
  2797. etherpad_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  2798. etherpad_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2799. etherpad_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2800. etherpad_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2801. etherpad_systemd_required_services_list: |
  2802. {{
  2803. [devture_systemd_docker_base_docker_service_name]
  2804. +
  2805. ([postgres_identifier ~ '.service'] if postgres_enabled else [])
  2806. }}
  2807. etherpad_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  2808. etherpad_database_name: matrix_etherpad
  2809. etherpad_database_username: matrix_etherpad
  2810. etherpad_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'etherpad.db', rounds=655555) | to_uuid }}"
  2811. ######################################################################
  2812. #
  2813. # /etke/etherpad
  2814. #
  2815. ######################################################################
  2816. ######################################################################
  2817. #
  2818. # matrix-dynamic-dns
  2819. #
  2820. ######################################################################
  2821. matrix_dynamic_dns_enabled: false
  2822. matrix_dynamic_dns_container_network: matrix-dynamic-dns
  2823. ######################################################################
  2824. #
  2825. # /matrix-dynamic-dns
  2826. #
  2827. ######################################################################
  2828. ######################################################################
  2829. #
  2830. # matrix-email2matrix
  2831. #
  2832. ######################################################################
  2833. matrix_email2matrix_enabled: false
  2834. matrix_email2matrix_systemd_required_services_list_auto: |
  2835. {{
  2836. matrix_addons_homeserver_systemd_services_list
  2837. }}
  2838. matrix_email2matrix_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm32', 'arm64'] }}"
  2839. matrix_email2matrix_container_network: "{{ matrix_addons_container_network }}"
  2840. matrix_email2matrix_container_additional_networks_auto: |-
  2841. {{
  2842. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2843. }}
  2844. ######################################################################
  2845. #
  2846. # /matrix-email2matrix
  2847. #
  2848. ######################################################################
  2849. ######################################################################
  2850. #
  2851. # jitsi
  2852. #
  2853. ######################################################################
  2854. jitsi_enabled: false
  2855. jitsi_architecture: "{{ matrix_architecture }}"
  2856. jitsi_hostname: "{{ matrix_server_fqn_jitsi }}"
  2857. jitsi_identifier: matrix-jitsi
  2858. jitsi_base_path: "{{ matrix_base_data_path }}/jitsi"
  2859. jitsi_uid: "{{ matrix_user_uid }}"
  2860. jitsi_gid: "{{ matrix_user_gid }}"
  2861. jitsi_user_username: "{{ matrix_user_username }}"
  2862. jitsi_web_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '13080') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2863. jitsi_web_container_additional_networks_auto: |
  2864. {{
  2865. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  2866. }}
  2867. jitsi_jvb_container_colibri_ws_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '13090') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2868. jitsi_jvb_container_additional_networks_auto: |
  2869. {{
  2870. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  2871. }}
  2872. jitsi_prosody_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '5280') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2873. jitsi_prosody_container_additional_networks_auto: |
  2874. {{
  2875. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  2876. }}
  2877. jitsi_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  2878. jitsi_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2879. jitsi_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2880. jitsi_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2881. jitsi_jibri_xmpp_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'jibri', rounds=655555) | to_uuid }}"
  2882. jitsi_jicofo_auth_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'jicofo', rounds=655555) | to_uuid }}"
  2883. jitsi_jvb_auth_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'jvb', rounds=655555) | to_uuid }}"
  2884. jitsi_web_stun_servers: |
  2885. {{
  2886. [
  2887. 'stun:' + matrix_server_fqn_matrix + ':5349',
  2888. 'stun:' + matrix_server_fqn_matrix + ':3478',
  2889. ]
  2890. if matrix_coturn_enabled
  2891. else [ 'stun:meet-jit-si-turnrelay.jitsi.net:443']
  2892. }}
  2893. # The Jitsi instance installed by this playbook is meant for embedding into Matrix clients, so framing is allowed.
  2894. jitsi_web_framing_enabled: true
  2895. # Jitsi (Prosody) only seems to support authenticating with Coturn using `auth-secret`, not `lt-cred-mech`.
  2896. # See: https://prosody.im/doc/coturn
  2897. jitsi_turn_credentials: "{{ matrix_coturn_turn_static_auth_secret if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'auth-secret') else '' }}"
  2898. jitsi_turn_host: "{{ ('turn.' + matrix_server_fqn_matrix) if matrix_coturn_enabled else '' }}"
  2899. jitsi_turns_host: "{{ ('turn.' + matrix_server_fqn_matrix) if matrix_coturn_enabled else '' }}"
  2900. jitsi_turn_port: "{{ matrix_coturn_container_stun_plain_host_bind_port.split(':')[-1] if matrix_coturn_enabled else '' }}"
  2901. jitsi_turns_port: "{{ matrix_coturn_container_stun_tls_host_bind_port.split(':')[-1] if matrix_coturn_enabled else '' }}"
  2902. # If the self-hosted Etherpad instance is available, it will also show up in Jitsi conferences,
  2903. # unless explicitly disabled by setting `jitsi_etherpad_enabled` to false.
  2904. # Falls back to the scalar.vector.im etherpad in case someone sets `jitsi_etherpad_enabled` to true,
  2905. # while also setting `etherpad_enabled` to false.
  2906. jitsi_etherpad_enabled: "{{ etherpad_enabled }}"
  2907. jitsi_etherpad_base: "{{ etherpad_base_url if etherpad_enabled else 'https://scalar.vector.im/etherpad' }}"
  2908. # Allow verification using JWT and matrix-UVS
  2909. jitsi_prosody_auth_matrix_uvs_sync_power_levels: "{{ matrix_user_verification_service_enabled }}"
  2910. jitsi_prosody_auth_matrix_uvs_auth_token: "{{ matrix_user_verification_service_uvs_auth_token }}"
  2911. jitsi_prosody_auth_matrix_uvs_location: "{{ matrix_user_verification_service_container_url }}"
  2912. jitsi_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  2913. # Gravatar is enabled by default upstream, but there's no need to leak data there needlessly
  2914. # when embedding Jitsi in Matrix rooms.
  2915. jitsi_disable_gravatar: true
  2916. ######################################################################
  2917. #
  2918. # /jitsi
  2919. #
  2920. ######################################################################
  2921. ######################################################################
  2922. #
  2923. # matrix-ldap-registration-proxy
  2924. #
  2925. ######################################################################
  2926. # This is only for users with a specific LDAP setup
  2927. matrix_ldap_registration_proxy_enabled: false
  2928. matrix_ldap_registration_proxy_hostname: "{{ matrix_server_fqn_matrix }}"
  2929. matrix_ldap_registration_proxy_matrix_server_url: "{{ matrix_addons_homeserver_client_api_url }}"
  2930. matrix_ldap_registration_proxy_systemd_required_services_list_auto: |
  2931. {{
  2932. matrix_addons_homeserver_systemd_services_list
  2933. }}
  2934. matrix_ldap_registration_proxy_container_network: "{{ matrix_addons_container_network }}"
  2935. matrix_ldap_registration_proxy_container_additional_networks_auto: |-
  2936. {{
  2937. (
  2938. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  2939. +
  2940. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_ldap_registration_proxy_container_labels_traefik_enabled) else [])
  2941. ) | unique
  2942. }}
  2943. matrix_ldap_registration_proxy_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  2944. matrix_ldap_registration_proxy_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  2945. matrix_ldap_registration_proxy_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  2946. matrix_ldap_registration_proxy_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  2947. ######################################################################
  2948. #
  2949. # /matrix-ldap-registration-proxy
  2950. #
  2951. ######################################################################
  2952. ########################################################################
  2953. # #
  2954. # exim-relay #
  2955. # #
  2956. ########################################################################
  2957. # We set up an Exim email relay by default.
  2958. # This is so that the homeserver and various other services can send emails through it.
  2959. # To completely disable this service, use: `exim_relay_enabled: false`
  2960. exim_relay_identifier: "matrix-exim-relay"
  2961. exim_relay_base_path: "{{ matrix_base_data_path }}/exim-relay"
  2962. exim_relay_uid: "{{ matrix_user_uid }}"
  2963. exim_relay_gid: "{{ matrix_user_gid }}"
  2964. exim_relay_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm32', 'arm64'] }}"
  2965. exim_relay_hostname: "{{ matrix_server_fqn_matrix }}"
  2966. exim_relay_sender_address: "matrix@{{ exim_relay_hostname }}"
  2967. ########################################################################
  2968. # #
  2969. # /exim-relay #
  2970. # #
  2971. ########################################################################
  2972. ######################################################################
  2973. #
  2974. # matrix-ma1sd
  2975. #
  2976. ######################################################################
  2977. # We no longer install the ma1sd identity server by default.
  2978. #
  2979. # The main reason we used to install ma1sd by default in the past was to
  2980. # prevent Element from talking to the `matrix.org` / `vector.im` identity servers,
  2981. # by forcing it to talk to our own self-hosted (but otherwise useless) identity server instead,
  2982. # thus preventing contact list leaks.
  2983. #
  2984. # Since Element no longer defaults to using a public identity server if another one is not provided,
  2985. # we can stop installing ma1sd.
  2986. matrix_ma1sd_enabled: false
  2987. matrix_ma1sd_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  2988. matrix_ma1sd_hostname: "{{ matrix_server_fqn_matrix }}"
  2989. matrix_ma1sd_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  2990. matrix_ma1sd_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '' ~ matrix_ma1sd_container_port | string) if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  2991. matrix_ma1sd_container_network: "{{ matrix_homeserver_container_network }}"
  2992. matrix_ma1sd_container_additional_networks_auto: |
  2993. {{
  2994. (
  2995. ([matrix_homeserver_container_network] if (matrix_ma1sd_container_network != matrix_homeserver_container_network) else [])
  2996. +
  2997. ([postgres_container_network] if (postgres_enabled and matrix_ma1sd_database_hostname == postgres_connection_hostname and matrix_ma1sd_container_network != postgres_container_network) else [])
  2998. +
  2999. ([exim_relay_container_network] if (exim_relay_enabled and matrix_ma1sd_threepid_medium_email_connectors_smtp_host == exim_relay_identifier and matrix_ma1sd_container_network != exim_relay_container_network) else [])
  3000. +
  3001. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_ma1sd_container_labels_traefik_enabled) else [])
  3002. ) | unique
  3003. }}
  3004. matrix_ma1sd_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3005. matrix_ma1sd_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3006. matrix_ma1sd_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3007. matrix_ma1sd_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3008. # We enable Synapse integration via its Postgres database by default.
  3009. # When using another Identity store, you might wish to disable this and define
  3010. # your own configuration in `matrix_ma1sd_configuration_extension_yaml`.
  3011. matrix_ma1sd_synapsesql_enabled: true
  3012. matrix_ma1sd_synapsesql_type: postgresql
  3013. matrix_ma1sd_synapsesql_connection: //{{ matrix_synapse_database_host }}/{{ matrix_synapse_database_database }}?user={{ matrix_synapse_database_user | urlencode() }}&password={{ matrix_synapse_database_password | urlencode() }}
  3014. matrix_ma1sd_dns_overwrite_enabled: true
  3015. matrix_ma1sd_dns_overwrite_homeserver_client_name: "{{ matrix_server_fqn_matrix }}"
  3016. matrix_ma1sd_dns_overwrite_homeserver_client_value: "{{ matrix_addons_homeserver_client_api_url }}"
  3017. # By default, we send mail through the exim relay service.
  3018. matrix_ma1sd_threepid_medium_email_identity_from: "{{ exim_relay_sender_address }}"
  3019. matrix_ma1sd_threepid_medium_email_connectors_smtp_host: "{{ exim_relay_identifier }}"
  3020. matrix_ma1sd_threepid_medium_email_connectors_smtp_port: 8025
  3021. matrix_ma1sd_threepid_medium_email_connectors_smtp_tls: 0
  3022. matrix_ma1sd_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  3023. matrix_ma1sd_systemd_required_services_list_auto: |
  3024. {{
  3025. matrix_addons_homeserver_systemd_services_list
  3026. +
  3027. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_ma1sd_database_hostname == postgres_connection_hostname) else [])
  3028. }}
  3029. matrix_ma1sd_systemd_wanted_services_list_auto: |
  3030. {{
  3031. ([exim_relay_identifier ~ '.service'] if (exim_relay_enabled and matrix_ma1sd_threepid_medium_email_connectors_smtp_host == exim_relay_identifier) else [])
  3032. }}
  3033. # Postgres is the default, except if not using internal Postgres server
  3034. matrix_ma1sd_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  3035. matrix_ma1sd_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  3036. matrix_ma1sd_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ma1sd.db', rounds=655555) | to_uuid }}"
  3037. ######################################################################
  3038. #
  3039. # /matrix-ma1sd
  3040. #
  3041. ######################################################################
  3042. ######################################################################
  3043. #
  3044. # matrix-media-repo
  3045. #
  3046. ######################################################################
  3047. matrix_media_repo_enabled: false
  3048. matrix_media_repo_container_network: "{{ matrix_homeserver_container_network }}"
  3049. matrix_media_repo_container_additional_networks: |
  3050. {{
  3051. (
  3052. ([matrix_homeserver_container_network] if (matrix_media_repo_container_network != matrix_homeserver_container_network) else [])
  3053. +
  3054. ([postgres_container_network] if (postgres_enabled and matrix_media_repo_database_hostname == postgres_connection_hostname and postgres_container_network != matrix_media_repo_container_network) else [])
  3055. +
  3056. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_media_repo_container_labels_traefik_enabled) else [])
  3057. ) | unique
  3058. }}
  3059. matrix_media_repo_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  3060. matrix_media_repo_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3061. matrix_media_repo_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3062. matrix_media_repo_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3063. matrix_media_repo_container_labels_traefik_internal_media_enabled: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled }}"
  3064. matrix_media_repo_container_labels_traefik_internal_media_entrypoints: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_name }}"
  3065. matrix_media_repo_container_labels_traefik_internal_matrix_client_media_enabled: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled }}"
  3066. matrix_media_repo_container_labels_traefik_internal_matrix_client_media_entrypoints: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_name }}"
  3067. matrix_media_repo_metrics_proxying_enabled: "{{ matrix_media_repo_metrics_enabled and matrix_metrics_exposure_enabled }}"
  3068. matrix_media_repo_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  3069. matrix_media_repo_metrics_proxying_path: "{{ matrix_metrics_exposure_path_prefix }}/matrix-media-repo"
  3070. matrix_media_repo_container_labels_traefik_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  3071. matrix_media_repo_container_labels_traefik_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  3072. matrix_media_repo_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  3073. matrix_media_repo_database_username: matrix_media_repo
  3074. matrix_media_repo_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mediarepo.db', rounds=655555) | to_uuid }}"
  3075. matrix_media_repo_database_name: matrix_media_repo
  3076. matrix_media_repo_systemd_required_services_list_auto: |
  3077. {{
  3078. matrix_addons_homeserver_systemd_services_list
  3079. +
  3080. ([postgres_identifier ~ '.service'] if postgres_enabled and matrix_media_repo_database_hostname == postgres_connection_hostname else [])
  3081. }}
  3082. matrix_media_repo_generate_signing_key: "{{ matrix_homeserver_implementation == 'synapse' or matrix_homeserver_implementation == 'dendrite'}}"
  3083. matrix_media_repo_homeserver_signing_key: "{{ matrix_media_repo_synapse_signing_key if matrix_homeserver_implementation == 'synapse' else (matrix_media_repo_dendrite_signing_key if matrix_homeserver_implementation == 'dendrite' else '') }}"
  3084. matrix_media_repo_synapse_signing_key: "{{ matrix_synapse_config_dir_path }}/{{ matrix_server_fqn_matrix }}.signing.key"
  3085. matrix_media_repo_dendrite_signing_key: "{{ matrix_dendrite_config_dir_path }}/{{ matrix_server_fqn_matrix }}.signing.pem"
  3086. # Auto configured server setup by the playbook
  3087. matrix_media_repo_homeservers_auto:
  3088. - # Keep the dash from this line.
  3089. # This should match the server_name of your homeserver, and the Host header
  3090. # provided to the media repo.
  3091. name: "{{ matrix_domain }}"
  3092. # The base URL to where the homeserver can actually be reached by MMR.
  3093. csApi: "{{ matrix_homeserver_container_url }}"
  3094. # The number of consecutive failures in calling this homeserver before the
  3095. # media repository will start backing off. This defaults to 10 if not given.
  3096. backoffAt: 10
  3097. # The admin API interface supported by the homeserver. MMR uses a subset of the admin API
  3098. # during certain operations, like attempting to purge media from a room or validating server
  3099. # admin status. This should be set to one of "synapse", "dendrite", or "matrix". When set
  3100. # to "matrix", most functionality requiring the admin API will not work.
  3101. adminApiKind: "{{ 'synapse' if matrix_homeserver_implementation == 'synapse' else ('dendrite' if matrix_homeserver_implementation == 'dendrite' else 'matrix') }}"
  3102. # The signing key to use for authorizing outbound federation requests. If not specified,
  3103. # requests will not be authorized. See https://docs.t2bot.io/matrix-media-repo/v1.3.5/installation/signing-key/
  3104. # for details.
  3105. signingKeyPath: "{{ '/config/' + matrix_media_repo_identifier + '.signing.key' if matrix_media_repo_generate_signing_key else '' }}"
  3106. matrix_media_repo_homeserver_federation_enabled: "{{ matrix_homeserver_federation_enabled }}"
  3107. ######################################################################
  3108. #
  3109. # /matrix-media-repo
  3110. #
  3111. ######################################################################
  3112. ########################################################################
  3113. # #
  3114. # postgres #
  3115. # #
  3116. ########################################################################
  3117. # To completely disable installing Postgres, use `postgres_enabled: false`.
  3118. postgres_identifier: matrix-postgres
  3119. postgres_architecture: "{{ matrix_architecture }}"
  3120. postgres_base_path: "{{ matrix_base_data_path }}/postgres"
  3121. postgres_uid: "{{ matrix_user_uid }}"
  3122. postgres_gid: "{{ matrix_user_gid }}"
  3123. postgres_connection_username: matrix
  3124. postgres_db_name: matrix
  3125. postgres_systemd_services_to_stop_for_maintenance_list_auto: "{{ devture_systemd_service_manager_services_list_auto | map(attribute='name') | reject('equalto', (postgres_identifier + '.service')) }}"
  3126. postgres_max_connections: "{{ 500 if matrix_synapse_workers_enabled else 200 }}"
  3127. postgres_managed_databases_auto: |
  3128. {{
  3129. ([{
  3130. 'name': matrix_synapse_database_database,
  3131. 'username': matrix_synapse_database_user,
  3132. 'password': matrix_synapse_database_password,
  3133. }] if (matrix_synapse_enabled and matrix_synapse_database_host == postgres_connection_hostname) else [])
  3134. +
  3135. ([{
  3136. 'name': matrix_dendrite_federation_api_database,
  3137. 'username': matrix_dendrite_database_user,
  3138. 'password': matrix_dendrite_database_password,
  3139. },{
  3140. 'name': matrix_dendrite_key_server_database,
  3141. 'username': matrix_dendrite_database_user,
  3142. 'password': matrix_dendrite_database_password,
  3143. },{
  3144. 'name': matrix_dendrite_media_api_database,
  3145. 'username': matrix_dendrite_database_user,
  3146. 'password': matrix_dendrite_database_password,
  3147. },{
  3148. 'name': matrix_dendrite_room_database,
  3149. 'username': matrix_dendrite_database_user,
  3150. 'password': matrix_dendrite_database_password,
  3151. },{
  3152. 'name': matrix_dendrite_sync_api_database,
  3153. 'username': matrix_dendrite_database_user,
  3154. 'password': matrix_dendrite_database_password,
  3155. },{
  3156. 'name': matrix_dendrite_user_api_database,
  3157. 'username': matrix_dendrite_database_user,
  3158. 'password': matrix_dendrite_database_password,
  3159. },{
  3160. 'name': matrix_dendrite_relay_api_database,
  3161. 'username': matrix_dendrite_database_user,
  3162. 'password': matrix_dendrite_database_password,
  3163. },{
  3164. 'name': matrix_dendrite_push_server_database,
  3165. 'username': matrix_dendrite_database_user,
  3166. 'password': matrix_dendrite_database_password,
  3167. },{
  3168. 'name': matrix_dendrite_mscs_database,
  3169. 'username': matrix_dendrite_database_user,
  3170. 'password': matrix_dendrite_database_password,
  3171. }] if (matrix_dendrite_enabled and matrix_dendrite_database_hostname == postgres_connection_hostname) else [])
  3172. +
  3173. ([{
  3174. 'name': matrix_authentication_service_config_database_database,
  3175. 'username': matrix_authentication_service_config_database_username,
  3176. 'password': matrix_authentication_service_config_database_password,
  3177. }] if (matrix_authentication_service_enabled and matrix_authentication_service_config_database_host == postgres_connection_hostname) else [])
  3178. +
  3179. ([{
  3180. 'name': matrix_sliding_sync_database_name,
  3181. 'username': matrix_sliding_sync_database_username,
  3182. 'password': matrix_sliding_sync_database_password,
  3183. }] if (matrix_sliding_sync_enabled) else [])
  3184. +
  3185. ([{
  3186. 'name': matrix_ma1sd_database_name,
  3187. 'username': matrix_ma1sd_database_username,
  3188. 'password': matrix_ma1sd_database_password,
  3189. }] if (matrix_ma1sd_enabled and matrix_ma1sd_database_engine == 'postgres' and matrix_ma1sd_database_hostname == postgres_connection_hostname) else [])
  3190. +
  3191. ([{
  3192. 'name': matrix_bot_matrix_reminder_bot_database_name,
  3193. 'username': matrix_bot_matrix_reminder_bot_database_username,
  3194. 'password': matrix_bot_matrix_reminder_bot_database_password,
  3195. }] if (matrix_bot_matrix_reminder_bot_enabled and matrix_bot_matrix_reminder_bot_database_engine == 'postgres' and matrix_bot_matrix_reminder_bot_database_hostname == postgres_connection_hostname) else [])
  3196. +
  3197. ([{
  3198. 'name': matrix_bot_honoroit_database_name,
  3199. 'username': matrix_bot_honoroit_database_username,
  3200. 'password': matrix_bot_honoroit_database_password,
  3201. }] if (matrix_bot_honoroit_enabled and matrix_bot_honoroit_database_engine == 'postgres' and matrix_bot_honoroit_database_hostname == postgres_connection_hostname) else [])
  3202. +
  3203. ([{
  3204. 'name': matrix_postmoogle_database_name,
  3205. 'username': matrix_postmoogle_database_username,
  3206. 'password': matrix_postmoogle_database_password,
  3207. }] if (matrix_postmoogle_enabled and matrix_postmoogle_database_engine == 'postgres' and matrix_postmoogle_database_hostname == postgres_connection_hostname) else [])
  3208. +
  3209. ([{
  3210. 'name': matrix_bot_maubot_database_name,
  3211. 'username': matrix_bot_maubot_database_username,
  3212. 'password': matrix_bot_maubot_database_password,
  3213. }] if (matrix_bot_maubot_enabled and matrix_bot_maubot_database_engine == 'postgres' and matrix_bot_maubot_database_hostname == postgres_connection_hostname) else [])
  3214. +
  3215. ([{
  3216. 'name': matrix_bot_buscarron_database_name,
  3217. 'username': matrix_bot_buscarron_database_username,
  3218. 'password': matrix_bot_buscarron_database_password,
  3219. }] if (matrix_bot_buscarron_enabled and matrix_bot_buscarron_database_engine == 'postgres' and matrix_bot_buscarron_database_hostname == postgres_connection_hostname) else [])
  3220. +
  3221. ([{
  3222. 'name': matrix_registration_database_name,
  3223. 'username': matrix_registration_database_username,
  3224. 'password': matrix_registration_database_password,
  3225. }] if (matrix_registration_enabled and matrix_registration_database_engine == 'postgres' and matrix_registration_database_hostname == postgres_connection_hostname) else [])
  3226. +
  3227. ([{
  3228. 'name': matrix_appservice_discord_database_name,
  3229. 'username': matrix_appservice_discord_database_username,
  3230. 'password': matrix_appservice_discord_database_password,
  3231. }] if (matrix_appservice_discord_enabled and matrix_appservice_discord_database_engine == 'postgres' and matrix_appservice_discord_database_hostname == postgres_connection_hostname) else [])
  3232. +
  3233. ([{
  3234. 'name': matrix_appservice_draupnir_for_all_database_name,
  3235. 'username': matrix_appservice_draupnir_for_all_database_username,
  3236. 'password': matrix_appservice_draupnir_for_all_database_password,
  3237. }] if (matrix_appservice_draupnir_for_all_enabled and matrix_appservice_draupnir_for_all_database_hostname == postgres_connection_hostname) else [])
  3238. +
  3239. ([{
  3240. 'name': matrix_appservice_slack_database_name,
  3241. 'username': matrix_appservice_slack_database_username,
  3242. 'password': matrix_appservice_slack_database_password,
  3243. }] if (matrix_appservice_slack_enabled and matrix_appservice_slack_database_engine == 'postgres' and matrix_appservice_slack_database_hostname == postgres_connection_hostname) else [])
  3244. +
  3245. ([{
  3246. 'name': matrix_appservice_irc_database_name,
  3247. 'username': matrix_appservice_irc_database_username,
  3248. 'password': matrix_appservice_irc_database_password,
  3249. }] if (matrix_appservice_irc_enabled and matrix_appservice_irc_database_engine == 'postgres' and matrix_appservice_irc_database_hostname == postgres_connection_hostname) else [])
  3250. +
  3251. ([{
  3252. 'name': matrix_appservice_kakaotalk_database_name,
  3253. 'username': matrix_appservice_kakaotalk_database_username,
  3254. 'password': matrix_appservice_kakaotalk_database_password,
  3255. }] if (matrix_appservice_kakaotalk_enabled and matrix_appservice_kakaotalk_database_engine == 'postgres' and matrix_appservice_kakaotalk_database_hostname == postgres_connection_hostname) else [])
  3256. +
  3257. ([{
  3258. 'name': matrix_beeper_linkedin_database_name,
  3259. 'username': matrix_beeper_linkedin_database_username,
  3260. 'password': matrix_beeper_linkedin_database_password,
  3261. }] if (matrix_beeper_linkedin_enabled and matrix_beeper_linkedin_database_engine == 'postgres' and matrix_beeper_linkedin_database_hostname == postgres_connection_hostname) else [])
  3262. +
  3263. ([{
  3264. 'name': matrix_go_skype_bridge_database_name,
  3265. 'username': matrix_go_skype_bridge_database_username,
  3266. 'password': matrix_go_skype_bridge_database_password,
  3267. }] if (matrix_go_skype_bridge_enabled and matrix_go_skype_bridge_database_engine == 'postgres' and matrix_go_skype_bridge_database_hostname == postgres_connection_hostname) else [])
  3268. +
  3269. ([{
  3270. 'name': matrix_wechat_database_name,
  3271. 'username': matrix_wechat_database_username,
  3272. 'password': matrix_wechat_database_password,
  3273. }] if (matrix_wechat_enabled and matrix_wechat_database_engine == 'postgres' and matrix_wechat_database_hostname == postgres_connection_hostname) else [])
  3274. +
  3275. ([{
  3276. 'name': matrix_mautrix_facebook_database_name,
  3277. 'username': matrix_mautrix_facebook_database_username,
  3278. 'password': matrix_mautrix_facebook_database_password,
  3279. }] if (matrix_mautrix_facebook_enabled and matrix_mautrix_facebook_database_engine == 'postgres' and matrix_mautrix_facebook_database_hostname == postgres_connection_hostname) else [])
  3280. +
  3281. ([{
  3282. 'name': matrix_mautrix_hangouts_database_name,
  3283. 'username': matrix_mautrix_hangouts_database_username,
  3284. 'password': matrix_mautrix_hangouts_database_password,
  3285. }] if (matrix_mautrix_hangouts_enabled and matrix_mautrix_hangouts_database_engine == 'postgres' and matrix_mautrix_hangouts_database_hostname == postgres_connection_hostname) else [])
  3286. +
  3287. ([{
  3288. 'name': matrix_mautrix_googlechat_database_name,
  3289. 'username': matrix_mautrix_googlechat_database_username,
  3290. 'password': matrix_mautrix_googlechat_database_password,
  3291. }] if (matrix_mautrix_googlechat_enabled and matrix_mautrix_googlechat_database_engine == 'postgres' and matrix_mautrix_googlechat_database_hostname == postgres_connection_hostname) else [])
  3292. +
  3293. ([{
  3294. 'name': matrix_mautrix_instagram_database_name,
  3295. 'username': matrix_mautrix_instagram_database_username,
  3296. 'password': matrix_mautrix_instagram_database_password,
  3297. }] if (matrix_mautrix_instagram_enabled and matrix_mautrix_instagram_database_engine == 'postgres' and matrix_mautrix_instagram_database_hostname == postgres_connection_hostname) else [])
  3298. +
  3299. ([{
  3300. 'name': matrix_mautrix_signal_database_name,
  3301. 'username': matrix_mautrix_signal_database_username,
  3302. 'password': matrix_mautrix_signal_database_password,
  3303. }] if (matrix_mautrix_signal_enabled and matrix_mautrix_signal_database_engine == 'postgres' and matrix_mautrix_signal_database_hostname == postgres_connection_hostname) else [])
  3304. +
  3305. ([{
  3306. 'name': matrix_mautrix_meta_messenger_database_name,
  3307. 'username': matrix_mautrix_meta_messenger_database_username,
  3308. 'password': matrix_mautrix_meta_messenger_database_password,
  3309. }] if (matrix_mautrix_meta_messenger_enabled and matrix_mautrix_meta_messenger_database_engine == 'postgres' and matrix_mautrix_meta_messenger_database_hostname == postgres_connection_hostname) else [])
  3310. +
  3311. ([{
  3312. 'name': matrix_mautrix_meta_instagram_database_name,
  3313. 'username': matrix_mautrix_meta_instagram_database_username,
  3314. 'password': matrix_mautrix_meta_instagram_database_password,
  3315. }] if (matrix_mautrix_meta_instagram_enabled and matrix_mautrix_meta_instagram_database_engine == 'postgres' and matrix_mautrix_meta_instagram_database_hostname == postgres_connection_hostname) else [])
  3316. +
  3317. ([{
  3318. 'name': matrix_mautrix_wsproxy_syncproxy_database_name,
  3319. 'username': matrix_mautrix_wsproxy_syncproxy_database_username,
  3320. 'password': matrix_mautrix_wsproxy_syncproxy_database_password,
  3321. }] if (matrix_mautrix_wsproxy_enabled and matrix_mautrix_wsproxy_syncproxy_database_engine == 'postgres' and matrix_mautrix_wsproxy_syncproxy_database_hostname == 'matrix-postgres') else [])
  3322. +
  3323. ([{
  3324. 'name': matrix_mautrix_telegram_database_name,
  3325. 'username': matrix_mautrix_telegram_database_username,
  3326. 'password': matrix_mautrix_telegram_database_password,
  3327. }] if (matrix_mautrix_telegram_enabled and matrix_mautrix_telegram_database_engine == 'postgres' and matrix_mautrix_telegram_database_hostname == postgres_connection_hostname) else [])
  3328. +
  3329. ([{
  3330. 'name': matrix_mautrix_twitter_database_name,
  3331. 'username': matrix_mautrix_twitter_database_username,
  3332. 'password': matrix_mautrix_twitter_database_password,
  3333. }] if (matrix_mautrix_twitter_enabled and matrix_mautrix_twitter_database_engine == 'postgres' and matrix_mautrix_twitter_database_hostname == postgres_connection_hostname) else [])
  3334. +
  3335. ([{
  3336. 'name': matrix_mautrix_gmessages_database_name,
  3337. 'username': matrix_mautrix_gmessages_database_username,
  3338. 'password': matrix_mautrix_gmessages_database_password,
  3339. }] if (matrix_mautrix_gmessages_enabled and matrix_mautrix_gmessages_database_engine == 'postgres' and matrix_mautrix_gmessages_database_hostname == postgres_connection_hostname) else [])
  3340. +
  3341. ([{
  3342. 'name': matrix_mautrix_whatsapp_database_name,
  3343. 'username': matrix_mautrix_whatsapp_database_username,
  3344. 'password': matrix_mautrix_whatsapp_database_password,
  3345. }] if (matrix_mautrix_whatsapp_enabled and matrix_mautrix_whatsapp_database_engine == 'postgres' and matrix_mautrix_whatsapp_database_hostname == postgres_connection_hostname) else [])
  3346. +
  3347. ([{
  3348. 'name': matrix_mautrix_discord_database_name,
  3349. 'username': matrix_mautrix_discord_database_username,
  3350. 'password': matrix_mautrix_discord_database_password,
  3351. }] if (matrix_mautrix_discord_enabled and matrix_mautrix_discord_database_engine == 'postgres' and matrix_mautrix_discord_database_hostname == postgres_connection_hostname) else [])
  3352. +
  3353. ([{
  3354. 'name': matrix_mautrix_slack_database_name,
  3355. 'username': matrix_mautrix_slack_database_username,
  3356. 'password': matrix_mautrix_slack_database_password,
  3357. }] if (matrix_mautrix_slack_enabled and matrix_mautrix_slack_database_engine == 'postgres' and matrix_mautrix_slack_database_hostname == postgres_connection_hostname) else [])
  3358. +
  3359. ([{
  3360. 'name': matrix_mx_puppet_slack_database_name,
  3361. 'username': matrix_mx_puppet_slack_database_username,
  3362. 'password': matrix_mx_puppet_slack_database_password,
  3363. }] if (matrix_mx_puppet_slack_enabled and matrix_mx_puppet_slack_database_engine == 'postgres' and matrix_mx_puppet_slack_database_hostname == postgres_connection_hostname) else [])
  3364. +
  3365. ([{
  3366. 'name': matrix_mx_puppet_twitter_database_name,
  3367. 'username': matrix_mx_puppet_twitter_database_username,
  3368. 'password': matrix_mx_puppet_twitter_database_password,
  3369. }] if (matrix_mx_puppet_twitter_enabled and matrix_mx_puppet_twitter_database_engine == 'postgres' and matrix_mx_puppet_twitter_database_hostname == postgres_connection_hostname) else [])
  3370. +
  3371. ([{
  3372. 'name': matrix_mx_puppet_instagram_database_name,
  3373. 'username': matrix_mx_puppet_instagram_database_username,
  3374. 'password': matrix_mx_puppet_instagram_database_password,
  3375. }] if (matrix_mx_puppet_instagram_enabled and matrix_mx_puppet_instagram_database_engine == 'postgres' and matrix_mx_puppet_instagram_database_hostname == postgres_connection_hostname) else [])
  3376. +
  3377. ([{
  3378. 'name': matrix_mx_puppet_discord_database_name,
  3379. 'username': matrix_mx_puppet_discord_database_username,
  3380. 'password': matrix_mx_puppet_discord_database_password,
  3381. }] if (matrix_mx_puppet_discord_enabled and matrix_mx_puppet_discord_database_engine == 'postgres' and matrix_mx_puppet_discord_database_hostname == postgres_connection_hostname) else [])
  3382. +
  3383. ([{
  3384. 'name': matrix_mx_puppet_steam_database_name,
  3385. 'username': matrix_mx_puppet_steam_database_username,
  3386. 'password': matrix_mx_puppet_steam_database_password,
  3387. }] if (matrix_mx_puppet_steam_enabled and matrix_mx_puppet_steam_database_engine == 'postgres' and matrix_mx_puppet_steam_database_hostname == postgres_connection_hostname) else [])
  3388. +
  3389. ([{
  3390. 'name': matrix_mx_puppet_groupme_database_name,
  3391. 'username': matrix_mx_puppet_groupme_database_username,
  3392. 'password': matrix_mx_puppet_groupme_database_password,
  3393. }] if (matrix_mx_puppet_groupme_enabled and matrix_mx_puppet_groupme_database_engine == 'postgres' and matrix_mx_puppet_groupme_database_hostname == postgres_connection_hostname) else [])
  3394. +
  3395. ([{
  3396. 'name': matrix_dimension_database_name,
  3397. 'username': matrix_dimension_database_username,
  3398. 'password': matrix_dimension_database_password,
  3399. }] if (matrix_dimension_enabled and matrix_dimension_database_engine == 'postgres' and matrix_dimension_database_hostname == postgres_connection_hostname) else [])
  3400. +
  3401. ([{
  3402. 'name': etherpad_database_name,
  3403. 'username': etherpad_database_username,
  3404. 'password': etherpad_database_password,
  3405. }] if (etherpad_enabled and etherpad_database_engine == 'postgres' and etherpad_database_hostname == postgres_connection_hostname) else [])
  3406. +
  3407. ([{
  3408. 'name': prometheus_postgres_exporter_database_name,
  3409. 'username': prometheus_postgres_exporter_database_username,
  3410. 'password': prometheus_postgres_exporter_database_password,
  3411. }] if (prometheus_postgres_exporter_enabled and prometheus_postgres_exporter_database_hostname == postgres_connection_hostname) else [])
  3412. +
  3413. ([{
  3414. 'name': matrix_media_repo_database_name,
  3415. 'username': matrix_media_repo_database_username,
  3416. 'password': matrix_media_repo_database_password,
  3417. }] if (matrix_media_repo_enabled and matrix_media_repo_database_hostname == postgres_connection_hostname) else [])
  3418. }}
  3419. ########################################################################
  3420. # #
  3421. # /postgres #
  3422. # #
  3423. ########################################################################
  3424. ########################################################################
  3425. # #
  3426. # postgres_backup #
  3427. # #
  3428. ########################################################################
  3429. postgres_backup_enabled: false
  3430. postgres_backup_identifier: matrix-postgres-backup
  3431. postgres_backup_architecture: "{{ matrix_architecture }}"
  3432. postgres_backup_base_path: "{{ matrix_base_data_path }}/postgres-backup"
  3433. postgres_backup_systemd_required_services_list_auto: |
  3434. {{
  3435. ([(postgres_identifier + '.service')] if (postgres_enabled and postgres_backup_connection_hostname == postgres_connection_hostname) else [])
  3436. }}
  3437. postgres_backup_container_network: "{{ (postgres_container_network if (postgres_enabled and postgres_backup_connection_hostname == postgres_connection_hostname) else postgres_backup_identifier) }}"
  3438. postgres_backup_container_additional_networks_auto: |-
  3439. {{
  3440. ([postgres_container_network] if (postgres_enabled and postgres_backup_connection_hostname == postgres_connection_hostname and postgres_backup_container_network != postgres_container_network) else [])
  3441. }}
  3442. postgres_backup_uid: "{{ matrix_user_uid }}"
  3443. postgres_backup_gid: "{{ matrix_user_gid }}"
  3444. postgres_backup_connection_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  3445. postgres_backup_connection_port: "{{ postgres_connection_port if postgres_enabled else 5432 }}"
  3446. postgres_backup_connection_username: "{{ postgres_connection_username if postgres_enabled else '' }}"
  3447. postgres_backup_connection_password: "{{ postgres_connection_password if postgres_enabled else '' }}"
  3448. postgres_backup_postgres_data_path: "{{ postgres_data_path if postgres_enabled else '' }}"
  3449. postgres_backup_postgres_role_include_name: galaxy/postgres
  3450. postgres_backup_databases: "{{ postgres_managed_databases | map(attribute='name') if postgres_enabled else [] }}"
  3451. ########################################################################
  3452. # #
  3453. # /postgres_backup #
  3454. # #
  3455. ########################################################################
  3456. ######################################################################
  3457. #
  3458. # matrix-sygnal
  3459. #
  3460. ######################################################################
  3461. # Most people don't need their own push-server, because they also need their own app to utilize it from.
  3462. matrix_sygnal_enabled: false
  3463. matrix_sygnal_metrics_prometheus_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  3464. matrix_sygnal_hostname: "{{ matrix_server_fqn_sygnal }}"
  3465. matrix_sygnal_container_network: "{{ matrix_homeserver_container_network }}"
  3466. matrix_sygnal_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [] }}"
  3467. matrix_sygnal_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '6000') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3468. matrix_sygnal_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  3469. matrix_sygnal_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3470. matrix_sygnal_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3471. matrix_sygnal_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3472. ######################################################################
  3473. #
  3474. # /matrix-sygnal
  3475. #
  3476. ######################################################################
  3477. ######################################################################
  3478. #
  3479. # etke/ntfy
  3480. #
  3481. ######################################################################
  3482. ntfy_enabled: false
  3483. ntfy_identifier: matrix-ntfy
  3484. ntfy_base_path: "{{ matrix_base_data_path }}/ntfy"
  3485. ntfy_uid: "{{ matrix_user_uid }}"
  3486. ntfy_gid: "{{ matrix_user_gid }}"
  3487. ntfy_hostname: "{{ matrix_server_fqn_ntfy }}"
  3488. ntfy_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [] }}"
  3489. ntfy_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '2586') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3490. ntfy_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  3491. ntfy_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3492. ntfy_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3493. ntfy_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3494. ntfy_visitor_request_limit_exempt_hosts_hostnames_auto: |
  3495. {{
  3496. [matrix_server_fqn_matrix]
  3497. }}
  3498. ######################################################################
  3499. #
  3500. # /etky/ntfy
  3501. #
  3502. ######################################################################
  3503. ######################################################################
  3504. #
  3505. # redis
  3506. #
  3507. ######################################################################
  3508. redis_enabled: "{{ not (keydb_enabled or valkey_enabled) and (matrix_synapse_workers_enabled or (matrix_hookshot_enabled and matrix_hookshot_encryption_enabled)) }}"
  3509. redis_identifier: matrix-redis
  3510. redis_uid: "{{ matrix_user_uid }}"
  3511. redis_gid: "{{ matrix_user_gid }}"
  3512. redis_base_path: "{{ matrix_base_data_path }}/redis"
  3513. ######################################################################
  3514. #
  3515. # /redis
  3516. #
  3517. ######################################################################
  3518. ######################################################################
  3519. #
  3520. # keydb
  3521. #
  3522. ######################################################################
  3523. keydb_enabled: false
  3524. keydb_identifier: matrix-keydb
  3525. keydb_uid: "{{ matrix_user_uid }}"
  3526. keydb_gid: "{{ matrix_user_gid }}"
  3527. keydb_base_path: "{{ matrix_base_data_path }}/keydb"
  3528. keydb_arch: |-
  3529. {{
  3530. ({
  3531. 'amd64': 'x86_64',
  3532. 'arm32': 'arm32',
  3533. 'arm64': 'arm64',
  3534. })[matrix_architecture]
  3535. }}
  3536. ######################################################################
  3537. #
  3538. # keydb
  3539. #
  3540. ######################################################################
  3541. ######################################################################
  3542. #
  3543. # valkey
  3544. #
  3545. ######################################################################
  3546. valkey_enabled: "{{ matrix_synapse_workers_enabled or (matrix_hookshot_enabled and matrix_hookshot_encryption_enabled) }}"
  3547. valkey_identifier: matrix-valkey
  3548. valkey_uid: "{{ matrix_user_uid }}"
  3549. valkey_gid: "{{ matrix_user_gid }}"
  3550. valkey_base_path: "{{ matrix_base_data_path }}/valkey"
  3551. valkey_arch: "{{ matrix_architecture }}"
  3552. ######################################################################
  3553. #
  3554. # valkey
  3555. #
  3556. ######################################################################
  3557. ######################################################################
  3558. #
  3559. # matrix-client-element
  3560. #
  3561. ######################################################################
  3562. # By default, this playbook installs the Element Web on the `matrix_server_fqn_element` domain.
  3563. # If you wish to connect to your Matrix server by other means, you may wish to disable this.
  3564. matrix_client_element_enabled: true
  3565. matrix_client_element_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  3566. matrix_client_element_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  3567. matrix_client_element_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8765') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3568. matrix_client_element_container_network: "{{ matrix_addons_container_network }}"
  3569. matrix_client_element_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_client_element_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}"
  3570. matrix_client_element_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3571. matrix_client_element_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3572. matrix_client_element_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3573. matrix_client_element_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3574. matrix_client_element_container_labels_traefik_compression_middleware_enabled: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled }}"
  3575. matrix_client_element_container_labels_traefik_compression_middleware_name: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_name if matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled else '' }}"
  3576. matrix_client_element_default_hs_url: "{{ matrix_homeserver_url }}"
  3577. matrix_client_element_default_is_url: "{{ matrix_identity_server_url }}"
  3578. # Use Dimension if enabled, otherwise fall back to Scalar
  3579. matrix_client_element_integrations_ui_url: "{{ matrix_dimension_integrations_ui_url if matrix_dimension_enabled else 'https://scalar.vector.im/' }}"
  3580. matrix_client_element_integrations_rest_url: "{{ matrix_dimension_integrations_rest_url if matrix_dimension_enabled else 'https://scalar.vector.im/api' }}"
  3581. matrix_client_element_integrations_widgets_urls: "{{ matrix_dimension_integrations_widgets_urls if matrix_dimension_enabled else ['https://scalar.vector.im/api'] }}"
  3582. matrix_client_element_integrations_jitsi_widget_url: "{{ matrix_dimension_integrations_jitsi_widget_url if matrix_dimension_enabled else 'https://scalar.vector.im/api/widgets/jitsi.html' }}"
  3583. matrix_client_element_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  3584. matrix_client_element_registration_enabled: "{{ matrix_synapse_enable_registration }}"
  3585. matrix_client_element_enable_presence_by_hs_url: |-
  3586. {{
  3587. none
  3588. if matrix_synapse_presence_enabled
  3589. else {matrix_client_element_default_hs_url: false}
  3590. }}
  3591. matrix_client_element_jitsi_preferred_domain: "{{ matrix_server_fqn_jitsi if jitsi_enabled else '' }}"
  3592. ######################################################################
  3593. #
  3594. # /matrix-client-element
  3595. #
  3596. ######################################################################
  3597. ######################################################################
  3598. #
  3599. # matrix-client-hydrogen
  3600. #
  3601. ######################################################################
  3602. matrix_client_hydrogen_enabled: false
  3603. matrix_client_hydrogen_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  3604. matrix_client_hydrogen_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8768') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3605. matrix_client_hydrogen_container_network: "{{ matrix_addons_container_network }}"
  3606. matrix_client_hydrogen_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_client_hydrogen_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}"
  3607. matrix_client_hydrogen_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3608. matrix_client_hydrogen_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3609. matrix_client_hydrogen_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3610. matrix_client_hydrogen_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3611. matrix_client_hydrogen_container_labels_traefik_compression_middleware_enabled: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled }}"
  3612. matrix_client_hydrogen_container_labels_traefik_compression_middleware_name: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_name if matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled else '' }}"
  3613. matrix_client_hydrogen_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  3614. matrix_client_hydrogen_default_hs_url: "{{ matrix_homeserver_url }}"
  3615. matrix_client_hydrogen_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  3616. ######################################################################
  3617. #
  3618. # /matrix-client-hydrogen
  3619. #
  3620. ######################################################################
  3621. ######################################################################
  3622. #
  3623. # matrix-client-cinny
  3624. #
  3625. ######################################################################
  3626. matrix_client_cinny_enabled: false
  3627. matrix_client_cinny_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  3628. matrix_client_cinny_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8080') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3629. matrix_client_cinny_container_network: "{{ matrix_addons_container_network }}"
  3630. matrix_client_cinny_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_client_cinny_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}"
  3631. matrix_client_cinny_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3632. matrix_client_cinny_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3633. matrix_client_cinny_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3634. matrix_client_cinny_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3635. matrix_client_cinny_container_labels_traefik_compression_middleware_enabled: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled }}"
  3636. matrix_client_cinny_container_labels_traefik_compression_middleware_name: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_name if matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled else '' }}"
  3637. matrix_client_cinny_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  3638. matrix_client_cinny_default_hs_url: "{{ matrix_homeserver_url }}"
  3639. matrix_client_cinny_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  3640. ######################################################################
  3641. #
  3642. # /matrix-client-cinny
  3643. #
  3644. ######################################################################
  3645. ######################################################################
  3646. #
  3647. # matrix-client-schildichat
  3648. #
  3649. ######################################################################
  3650. matrix_client_schildichat_enabled: false
  3651. matrix_client_schildichat_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  3652. matrix_client_schildichat_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  3653. matrix_client_schildichat_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8765') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3654. matrix_client_schildichat_container_network: "{{ matrix_addons_container_network }}"
  3655. matrix_client_schildichat_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_client_schildichat_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network) else [] }}"
  3656. matrix_client_schildichat_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3657. matrix_client_schildichat_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3658. matrix_client_schildichat_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3659. matrix_client_schildichat_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3660. matrix_client_schildichat_default_hs_url: "{{ matrix_homeserver_url }}"
  3661. matrix_client_schildichat_default_is_url: "{{ matrix_identity_server_url }}"
  3662. # Use Dimension if enabled, otherwise fall back to Scalar
  3663. matrix_client_schildichat_integrations_ui_url: "{{ matrix_dimension_integrations_ui_url if matrix_dimension_enabled else 'https://scalar.vector.im/' }}"
  3664. matrix_client_schildichat_integrations_rest_url: "{{ matrix_dimension_integrations_rest_url if matrix_dimension_enabled else 'https://scalar.vector.im/api' }}"
  3665. matrix_client_schildichat_integrations_widgets_urls: "{{ matrix_dimension_integrations_widgets_urls if matrix_dimension_enabled else ['https://scalar.vector.im/api'] }}"
  3666. matrix_client_schildichat_integrations_jitsi_widget_url: "{{ matrix_dimension_integrations_jitsi_widget_url if matrix_dimension_enabled else 'https://scalar.vector.im/api/widgets/jitsi.html' }}"
  3667. matrix_client_schildichat_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  3668. matrix_client_schildichat_registration_enabled: "{{ matrix_synapse_enable_registration }}"
  3669. matrix_client_schildichat_enable_presence_by_hs_url: |-
  3670. {{
  3671. none
  3672. if matrix_synapse_presence_enabled
  3673. else {matrix_client_schildichat_default_hs_url: false}
  3674. }}
  3675. matrix_client_schildichat_jitsi_preferred_domain: "{{ matrix_server_fqn_jitsi if jitsi_enabled else '' }}"
  3676. ######################################################################
  3677. #
  3678. # /matrix-client-schildichat
  3679. #
  3680. ######################################################################
  3681. ######################################################################
  3682. #
  3683. # matrix-synapse
  3684. #
  3685. ######################################################################
  3686. matrix_synapse_enabled: "{{ matrix_homeserver_implementation == 'synapse' }}"
  3687. matrix_synapse_username: "{{ matrix_user_username }}"
  3688. matrix_synapse_uid: "{{ matrix_user_uid }}"
  3689. matrix_synapse_gid: "{{ matrix_user_gid }}"
  3690. matrix_synapse_federation_enabled: "{{ matrix_homeserver_federation_enabled }}"
  3691. matrix_synapse_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  3692. matrix_synapse_account_threepid_delegates_msisdn_mas1sd_url: "{{ ('http://matrix-ma1sd:' + matrix_ma1sd_container_port| string) }}"
  3693. # When ma1sd is enabled, we can use it to validate phone numbers. It's something that the homeserver cannot do by itself.
  3694. matrix_synapse_account_threepid_delegates_msisdn: "{{ matrix_synapse_account_threepid_delegates_msisdn_mas1sd_url if matrix_ma1sd_enabled else '' }}"
  3695. # For exposing the Matrix Federation API's TLS port (HTTPS) to the internet on all network interfaces.
  3696. matrix_synapse_container_federation_api_tls_host_bind_port: "{{ matrix_federation_public_port if (matrix_synapse_federation_enabled and matrix_synapse_tls_federation_listener_enabled) else '' }}"
  3697. #
  3698. # For exposing the Synapse Metrics API's port (plain HTTP) to the local host.
  3699. matrix_synapse_container_metrics_api_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9100') if matrix_synapse_metrics_enabled and matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3700. #
  3701. # For exposing the Synapse Manhole port (plain HTTP) to the local host.
  3702. matrix_synapse_container_manhole_api_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9000') if matrix_synapse_metrics_enabled and matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3703. matrix_synapse_container_network: "{{ matrix_homeserver_container_network }}"
  3704. matrix_synapse_container_additional_networks_auto: |
  3705. {{
  3706. (
  3707. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_synapse_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network else [])
  3708. +
  3709. ([postgres_container_network] if (postgres_enabled and postgres_container_network != matrix_synapse_container_network and matrix_synapse_database_host == postgres_connection_hostname) else [])
  3710. +
  3711. ([redis_container_network] if matrix_synapse_redis_enabled and matrix_synapse_redis_host == redis_identifier else [])
  3712. +
  3713. ([keydb_container_network] if matrix_synapse_redis_enabled and matrix_synapse_redis_host == keydb_identifier else [])
  3714. +
  3715. ([valkey_container_network] if matrix_synapse_redis_enabled and matrix_synapse_redis_host == valkey_identifier else [])
  3716. +
  3717. ([exim_relay_container_network] if (exim_relay_enabled and matrix_synapse_email_enabled and matrix_synapse_email_smtp_host == exim_relay_identifier and matrix_synapse_container_network != exim_relay_container_network) else [])
  3718. +
  3719. ([matrix_ma1sd_container_network] if (matrix_ma1sd_enabled and matrix_synapse_account_threepid_delegates_msisdn == matrix_synapse_account_threepid_delegates_msisdn_mas1sd_url and matrix_synapse_container_network != matrix_ma1sd_container_network) else [])
  3720. ) | unique
  3721. }}
  3722. matrix_synapse_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3723. matrix_synapse_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3724. matrix_synapse_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3725. matrix_synapse_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3726. matrix_synapse_container_labels_traefik_hostname: "{{ matrix_server_fqn_matrix }}"
  3727. matrix_synapse_container_labels_traefik_compression_middleware_enabled: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled }}"
  3728. matrix_synapse_container_labels_traefik_compression_middleware_name: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_name if matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled else '' }}"
  3729. matrix_synapse_container_labels_matrix_labels_enabled: "{{ not matrix_synapse_workers_enabled }}"
  3730. matrix_synapse_container_labels_public_client_root_redirection_enabled: "{{ matrix_synapse_container_labels_public_client_root_redirection_url != '' }}"
  3731. matrix_synapse_container_labels_public_client_root_redirection_url: "{{ (('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_element) if matrix_client_element_enabled else '' }}"
  3732. matrix_synapse_container_labels_public_client_synapse_admin_api_enabled: "{{ matrix_synapse_admin_enabled }}"
  3733. matrix_synapse_container_labels_public_federation_api_traefik_hostname: "{{ matrix_server_fqn_matrix_federation }}"
  3734. matrix_synapse_container_labels_public_federation_api_traefik_entrypoints: "{{ matrix_federation_traefik_entrypoint_name }}"
  3735. matrix_synapse_container_labels_public_federation_api_traefik_tls: "{{ matrix_federation_traefik_entrypoint_tls }}"
  3736. matrix_synapse_container_labels_public_federation_api_traefik_tls_certResolver: "{{ matrix_synapse_container_labels_traefik_tls_certResolver }}" # noqa var-naming
  3737. matrix_synapse_container_labels_public_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  3738. matrix_synapse_container_labels_public_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  3739. matrix_synapse_container_labels_internal_client_api_enabled: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled }}"
  3740. matrix_synapse_container_labels_internal_client_api_traefik_entrypoints: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_name }}"
  3741. # For exposing the Synapse worker (and metrics) ports to the local host.
  3742. matrix_synapse_workers_container_host_bind_address: "{{ matrix_playbook_service_host_bind_interface_prefix[0:-1] if (matrix_synapse_workers_enabled and matrix_playbook_service_host_bind_interface_prefix) else '' }}"
  3743. matrix_synapse_database_host: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  3744. matrix_synapse_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'synapse.db', rounds=655555) | to_uuid }}"
  3745. matrix_synapse_macaroon_secret_key: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'synapse.mac', rounds=655555) | to_uuid }}"
  3746. # We do not enable TLS in Synapse by default, since it's handled by Traefik.
  3747. matrix_synapse_tls_federation_listener_enabled: false
  3748. matrix_synapse_tls_certificate_path: ~
  3749. matrix_synapse_tls_private_key_path: ~
  3750. matrix_synapse_federation_port_openid_resource_required: "{{ not matrix_synapse_federation_enabled and (matrix_dimension_enabled or matrix_ma1sd_enabled or matrix_user_verification_service_enabled) }}"
  3751. matrix_synapse_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  3752. matrix_synapse_metrics_proxying_enabled: "{{ matrix_synapse_metrics_enabled and matrix_metrics_exposure_enabled }}"
  3753. matrix_synapse_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  3754. matrix_synapse_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/synapse"
  3755. matrix_synapse_email_enabled: "{{ exim_relay_enabled }}"
  3756. matrix_synapse_email_smtp_host: "{{ exim_relay_identifier }}"
  3757. matrix_synapse_email_smtp_port: 8025
  3758. matrix_synapse_email_smtp_require_transport_security: false
  3759. matrix_synapse_email_notif_from: "Matrix <{{ exim_relay_sender_address }}>"
  3760. matrix_synapse_turn_uris: |
  3761. {{
  3762. ([
  3763. 'turns:' + matrix_server_fqn_matrix + '?transport=udp',
  3764. 'turns:' + matrix_server_fqn_matrix + '?transport=tcp',
  3765. ] if matrix_coturn_enabled and matrix_coturn_tls_enabled else [])
  3766. +
  3767. ([
  3768. 'turn:' + matrix_server_fqn_matrix + '?transport=udp',
  3769. 'turn:' + matrix_server_fqn_matrix + '?transport=tcp',
  3770. ] if matrix_coturn_enabled else [])
  3771. }}
  3772. matrix_synapse_turn_shared_secret: "{{ matrix_coturn_turn_static_auth_secret if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'auth-secret') else '' }}"
  3773. matrix_synapse_turn_username: "{{ matrix_coturn_lt_cred_mech_username if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'lt-cred-mech') else '' }}"
  3774. matrix_synapse_turn_password: "{{ matrix_coturn_lt_cred_mech_password if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'lt-cred-mech') else '' }}"
  3775. matrix_synapse_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  3776. matrix_synapse_systemd_required_services_list_auto: |
  3777. {{
  3778. ([postgres_identifier ~ '.service'] if (postgres_enabled and postgres_container_network != matrix_synapse_container_network and matrix_synapse_database_host == postgres_connection_hostname) else [])
  3779. +
  3780. ([redis_identifier ~ '.service'] if matrix_synapse_redis_enabled and matrix_synapse_redis_host == redis_identifier else [])
  3781. +
  3782. ([keydb_identifier ~ '.service'] if matrix_synapse_redis_enabled and matrix_synapse_redis_host == keydb_identifier else [])
  3783. +
  3784. ([valkey_identifier ~ '.service'] if matrix_synapse_redis_enabled and matrix_synapse_redis_host == valkey_identifier else [])
  3785. +
  3786. (['matrix-goofys.service'] if matrix_s3_media_store_enabled else [])
  3787. +
  3788. (['matrix-authentication-service.service'] if (matrix_authentication_service_enabled and matrix_synapse_experimental_features_msc3861_enabled) else [])
  3789. }}
  3790. matrix_synapse_systemd_wanted_services_list_auto: |
  3791. {{
  3792. (['matrix-coturn.service'] if matrix_coturn_enabled else [])
  3793. +
  3794. ([exim_relay_identifier ~ '.service'] if exim_relay_enabled else [])
  3795. }}
  3796. # Synapse workers (used for parallel load-scaling) need Redis for IPC.
  3797. matrix_synapse_redis_enabled: "{{ redis_enabled or keydb_enabled or valkey_enabled }}"
  3798. matrix_synapse_redis_host: "{{ valkey_identifier if valkey_enabled else (redis_identifier if redis_enabled else (keydb_identifier if keydb_enabled else '')) }}"
  3799. matrix_synapse_redis_password: "{{ valkey_connection_password if valkey_enabled else (redis_connection_password if redis_enabled else (keydb_connection_password if keydb_enabled else '')) }}"
  3800. matrix_synapse_container_extra_arguments_auto: "{{ matrix_homeserver_container_extra_arguments_auto }}"
  3801. matrix_synapse_app_service_config_files_auto: "{{ matrix_homeserver_app_service_config_files_auto }}"
  3802. # Disable creation of media repository Synapse worker when using media-repo
  3803. matrix_synapse_ext_media_repo_enabled: "{{ matrix_media_repo_enabled }}"
  3804. # Enable Synapse statistics reporting when using synapse-usage-exporter
  3805. matrix_synapse_report_stats: "{{ matrix_synapse_usage_exporter_enabled }}"
  3806. matrix_synapse_report_stats_endpoint: "http://{{ matrix_synapse_usage_exporter_identifier }}:{{ matrix_synapse_usage_exporter_container_port | string }}/report-usage-stats/push"
  3807. matrix_synapse_experimental_features_msc3861_enabled: "{{ matrix_authentication_service_enabled and not matrix_authentication_service_migration_in_progress }}"
  3808. matrix_synapse_experimental_features_msc3861_issuer: "{{ matrix_authentication_service_http_base_container_url if matrix_authentication_service_enabled else '' }}"
  3809. matrix_synapse_experimental_features_msc3861_client_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'syn.ngauth.cs', rounds=655555) | to_uuid }}"
  3810. matrix_synapse_experimental_features_msc3861_admin_token: "{{ matrix_authentication_service_config_matrix_secret if matrix_authentication_service_enabled else '' }}"
  3811. matrix_synapse_experimental_features_msc3861_account_management_url: "{{ matrix_authentication_service_account_management_url if matrix_authentication_service_enabled else '' }}"
  3812. matrix_synapse_experimental_features_msc4108_enabled: "{{ matrix_authentication_service_enabled and not matrix_authentication_service_migration_in_progress }}"
  3813. # Disable password authentication when delegating authentication to Matrix Authentication Service.
  3814. # Unless this is done, Synapse fails on startup with:
  3815. # > Error in configuration at 'password_config.enabled':
  3816. # > Password auth cannot be enabled when OAuth delegation is enabled
  3817. matrix_synapse_password_config_enabled: "{{ not matrix_synapse_experimental_features_msc3861_enabled }}"
  3818. matrix_synapse_register_user_script_matrix_authentication_service_path: "{{ matrix_authentication_service_bin_path }}/register-user"
  3819. ######################################################################
  3820. #
  3821. # /matrix-synapse
  3822. #
  3823. ######################################################################
  3824. ######################################################################
  3825. #
  3826. # matrix-synapse-auto-compressor
  3827. #
  3828. ######################################################################
  3829. # Not enabled by default, for now
  3830. matrix_synapse_auto_compressor_enabled: false
  3831. matrix_synapse_auto_compressor_uid: "{{ matrix_user_uid }}"
  3832. matrix_synapse_auto_compressor_gid: "{{ matrix_user_gid }}"
  3833. matrix_synapse_auto_compressor_postgres_image: "{{ postgres_container_image_to_use }}"
  3834. matrix_synapse_auto_compressor_container_image_self_build: "{{ matrix_architecture not in ['amd64'] }}"
  3835. matrix_synapse_auto_compressor_container_network: "{{ (postgres_container_network if (postgres_enabled and matrix_synapse_auto_compressor_database_hostname == matrix_synapse_database_host and matrix_synapse_database_host == postgres_connection_hostname) else 'matrix-synapse-auto-compressor') }}"
  3836. matrix_synapse_auto_compressor_database_username: "{{ matrix_synapse_database_user if matrix_synapse_enabled else '' }}"
  3837. matrix_synapse_auto_compressor_database_password: "{{ matrix_synapse_database_password if matrix_synapse_enabled else '' }}"
  3838. matrix_synapse_auto_compressor_database_hostname: "{{ matrix_synapse_database_host if matrix_synapse_enabled else '' }}"
  3839. matrix_synapse_auto_compressor_database_port: "{{ matrix_synapse_database_port if matrix_synapse_enabled else '5432' }}"
  3840. matrix_synapse_auto_compressor_database_name: "{{ matrix_synapse_database_database if matrix_synapse_enabled else '' }}"
  3841. matrix_synapse_auto_compressor_systemd_required_services_list_auto: |
  3842. {{
  3843. ([postgres_identifier ~ '.service'] if (matrix_synapse_auto_compressor_container_network == postgres_container_network) else [])
  3844. }}
  3845. ######################################################################
  3846. #
  3847. # /matrix-synapse-auto-compressor
  3848. #
  3849. ######################################################################
  3850. ######################################################################
  3851. #
  3852. # matrix-synapse-reverse-proxy-companion
  3853. #
  3854. ######################################################################
  3855. matrix_synapse_reverse_proxy_companion_enabled: "{{ matrix_synapse_enabled and matrix_synapse_workers_enabled }}"
  3856. matrix_synapse_reverse_proxy_companion_container_network: "{{ matrix_synapse_container_network }}"
  3857. matrix_synapse_reverse_proxy_companion_container_additional_networks_auto: |
  3858. {{
  3859. (
  3860. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_synapse_reverse_proxy_companion_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network else [])
  3861. +
  3862. ([matrix_prometheus_nginxlog_exporter_container_network] if (matrix_prometheus_nginxlog_exporter_enabled and matrix_prometheus_nginxlog_exporter_container_network != matrix_synapse_reverse_proxy_companion_container_network) else [])
  3863. +
  3864. ([] if matrix_homeserver_container_network in ['', matrix_synapse_reverse_proxy_companion_container_network] else [matrix_homeserver_container_network])
  3865. ) | unique
  3866. }}
  3867. matrix_synapse_reverse_proxy_companion_client_api_client_max_body_size_mb: "{{ matrix_synapse_max_upload_size_mb }}"
  3868. matrix_synapse_reverse_proxy_companion_container_client_api_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8008') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3869. matrix_synapse_reverse_proxy_companion_container_federation_api_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8048') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3870. matrix_synapse_reverse_proxy_companion_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3871. matrix_synapse_reverse_proxy_companion_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3872. matrix_synapse_reverse_proxy_companion_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3873. matrix_synapse_reverse_proxy_companion_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3874. matrix_synapse_reverse_proxy_companion_container_labels_traefik_hostname: "{{ matrix_server_fqn_matrix }}"
  3875. matrix_synapse_reverse_proxy_companion_container_labels_traefik_compression_middleware_enabled: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled }}"
  3876. matrix_synapse_reverse_proxy_companion_container_labels_traefik_compression_middleware_name: "{{ matrix_playbook_reverse_proxy_traefik_middleware_compression_name if matrix_playbook_reverse_proxy_traefik_middleware_compression_enabled else '' }}"
  3877. matrix_synapse_reverse_proxy_companion_container_labels_public_client_synapse_client_api_enabled: "{{ matrix_synapse_container_labels_public_client_synapse_client_api_enabled }}"
  3878. matrix_synapse_reverse_proxy_companion_container_labels_public_client_synapse_admin_api_enabled: "{{ matrix_synapse_container_labels_public_client_synapse_admin_api_enabled }}"
  3879. matrix_synapse_reverse_proxy_companion_container_labels_public_federation_api_traefik_entrypoints: "{{ matrix_synapse_container_labels_public_federation_api_traefik_entrypoints }}"
  3880. matrix_synapse_reverse_proxy_companion_container_labels_public_federation_api_traefik_tls: "{{ matrix_synapse_container_labels_public_federation_api_traefik_tls }}"
  3881. matrix_synapse_reverse_proxy_companion_container_labels_internal_client_api_enabled: "{{ matrix_synapse_container_labels_internal_client_api_enabled }}"
  3882. matrix_synapse_reverse_proxy_companion_container_labels_internal_client_api_traefik_entrypoints: "{{ matrix_synapse_container_labels_internal_client_api_traefik_entrypoints }}"
  3883. matrix_synapse_reverse_proxy_companion_synapse_workers_enabled: "{{ matrix_synapse_workers_enabled }}"
  3884. matrix_synapse_reverse_proxy_companion_synapse_workers_list: "{{ matrix_synapse_workers_enabled_list }}"
  3885. matrix_synapse_reverse_proxy_companion_synapse_room_worker_client_server_locations: "{{ matrix_synapse_workers_room_worker_client_server_endpoints }}"
  3886. matrix_synapse_reverse_proxy_companion_synapse_room_worker_federation_locations: "{{ matrix_synapse_workers_room_worker_federation_endpoints }}"
  3887. matrix_synapse_reverse_proxy_companion_synapse_sync_worker_client_server_locations: "{{ matrix_synapse_workers_sync_worker_client_server_endpoints }}"
  3888. matrix_synapse_reverse_proxy_companion_synapse_client_reader_client_server_locations: "{{ matrix_synapse_workers_client_reader_client_server_endpoints }}"
  3889. matrix_synapse_reverse_proxy_companion_synapse_federation_reader_federation_locations: "{{ matrix_synapse_workers_federation_reader_federation_endpoints }}"
  3890. matrix_synapse_reverse_proxy_companion_synapse_generic_worker_client_server_locations: "{{ matrix_synapse_workers_generic_worker_client_server_endpoints }}"
  3891. matrix_synapse_reverse_proxy_companion_synapse_generic_worker_federation_locations: "{{ matrix_synapse_workers_generic_worker_federation_endpoints }}"
  3892. matrix_synapse_reverse_proxy_companion_synapse_stream_writer_typing_stream_worker_client_server_locations: "{{ matrix_synapse_workers_stream_writer_typing_stream_worker_client_server_endpoints }}"
  3893. matrix_synapse_reverse_proxy_companion_synapse_stream_writer_to_device_stream_worker_client_server_locations: "{{ matrix_synapse_workers_stream_writer_to_device_stream_worker_client_server_endpoints }}"
  3894. matrix_synapse_reverse_proxy_companion_synapse_stream_writer_account_data_stream_worker_client_server_locations: "{{ matrix_synapse_workers_stream_writer_account_data_stream_worker_client_server_endpoints }}"
  3895. matrix_synapse_reverse_proxy_companion_synapse_stream_writer_receipts_stream_worker_client_server_locations: "{{ matrix_synapse_workers_stream_writer_receipts_stream_worker_client_server_endpoints }}"
  3896. matrix_synapse_reverse_proxy_companion_synapse_stream_writer_presence_stream_worker_client_server_locations: "{{ matrix_synapse_workers_stream_writer_presence_stream_worker_client_server_endpoints }}"
  3897. matrix_synapse_reverse_proxy_companion_synapse_media_repository_locations: "{{matrix_synapse_workers_media_repository_endpoints|default([]) }}"
  3898. matrix_synapse_reverse_proxy_companion_synapse_user_dir_locations: "{{ matrix_synapse_workers_user_dir_worker_client_server_endpoints|default([]) }}"
  3899. matrix_synapse_reverse_proxy_companion_access_log_syslog_integration_enabled: "{{ matrix_prometheus_nginxlog_exporter_enabled }}"
  3900. matrix_synapse_reverse_proxy_companion_access_log_syslog_integration_server_port: "{{ (matrix_prometheus_nginxlog_exporter_identifier | string +':'+ matrix_prometheus_nginxlog_exporter_container_syslog_port | string) | default('') }}"
  3901. ######################################################################
  3902. #
  3903. # /matrix-synapse-reverse-proxy-companion
  3904. #
  3905. ######################################################################
  3906. ######################################################################
  3907. #
  3908. # matrix-synapse-admin
  3909. #
  3910. ######################################################################
  3911. matrix_synapse_admin_enabled: false
  3912. matrix_synapse_admin_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8766') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  3913. matrix_synapse_admin_container_image_self_build: "{{ matrix_architecture not in ['arm64', 'amd64'] }}"
  3914. matrix_synapse_admin_container_network: "{{ matrix_addons_container_network }}"
  3915. matrix_synapse_admin_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [] }}"
  3916. matrix_synapse_admin_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  3917. matrix_synapse_admin_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  3918. matrix_synapse_admin_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  3919. matrix_synapse_admin_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  3920. matrix_synapse_admin_config_asManagedUsers_auto: |
  3921. {{
  3922. ([
  3923. '^@'+(matrix_alertmanager_receiver_config_matrix_user_id_localpart | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3924. ] if matrix_alertmanager_receiver_enabled else [])
  3925. +
  3926. ([
  3927. '^@'+(matrix_appservice_draupnir_for_all_user_prefix | default('') | regex_escape) +'_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3928. ] if matrix_appservice_draupnir_for_all_enabled else [])
  3929. +
  3930. ([
  3931. '^@'+(matrix_bot_baibot_config_user_mxid_localpart | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3932. ] if matrix_bot_baibot_enabled else [])
  3933. +
  3934. ([
  3935. '^@'+(matrix_bot_buscarron_login | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3936. ] if matrix_bot_buscarron_enabled else [])
  3937. +
  3938. ([
  3939. '^@'+(matrix_bot_chatgpt_matrix_bot_username_localpart | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3940. ] if matrix_bot_chatgpt_enabled else [])
  3941. +
  3942. ([
  3943. '^@'+(matrix_bot_honoroit_login | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3944. ] if matrix_bot_honoroit_enabled else [])
  3945. +
  3946. ([
  3947. '^@'+(matrix_bot_matrix_registration_bot_matrix_user_id_localpart | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3948. ] if matrix_bot_matrix_registration_bot_enabled else [])
  3949. +
  3950. ([
  3951. '^@'+(matrix_bot_matrix_reminder_bot_matrix_user_id_localpart | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3952. ] if matrix_bot_matrix_reminder_bot_enabled else [])
  3953. +
  3954. ([
  3955. '^@'+(matrix_bot_maubot_login | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3956. ] if matrix_bot_maubot_enabled else [])
  3957. +
  3958. ([
  3959. '^@'+(matrix_postmoogle_login | default('') | regex_escape) +':'+(matrix_domain | regex_escape)+'$',
  3960. ] if matrix_postmoogle_enabled else [])
  3961. +
  3962. ([
  3963. '^@_discord_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3964. ] if matrix_appservice_discord_enabled else [])
  3965. +
  3966. ([
  3967. '^@'+(matrix_appservice_slack_bot_name | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  3968. '^@'+(matrix_appservice_slack_user_prefix | default('') | regex_escape)+'[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3969. ] if matrix_appservice_slack_enabled else [])
  3970. +
  3971. ([
  3972. '^@'+(matrix_appservice_webhooks_bot_name | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  3973. '^@'+(matrix_appservice_webhooks_user_prefix | default('') | regex_escape)+'[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3974. ] if matrix_appservice_webhooks_enabled else [])
  3975. +
  3976. ([
  3977. '^@'+(matrix_beeper_linkedin_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  3978. '^@linkedin_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3979. ] if matrix_beeper_linkedin_enabled else [])
  3980. +
  3981. ([
  3982. '^@'+(matrix_go_skype_bridge_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  3983. '^@skype_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3984. ] if matrix_go_skype_bridge_enabled else [])
  3985. +
  3986. ([
  3987. '^@heisenbridge:'+(matrix_domain | regex_escape)+'$',
  3988. '^@hbirc_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3989. ] if matrix_heisenbridge_enabled else [])
  3990. +
  3991. ([
  3992. '^@hookshot:'+(matrix_domain | regex_escape)+'$',
  3993. '^@_github_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3994. '^@_gitlab_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3995. '^@_jira_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3996. '^@'+(matrix_hookshot_generic_userIdPrefix | default('') | regex_escape)+'[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  3997. ] if matrix_hookshot_enabled else [])
  3998. +
  3999. ([
  4000. '^@'+(matrix_mautrix_discord_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4001. '^@discord_[0-9]+:'+(matrix_domain | regex_escape)+'$',
  4002. ] if matrix_mautrix_discord_enabled else [])
  4003. +
  4004. ([
  4005. '^@'+(matrix_mautrix_facebook_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4006. '^@facebook_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4007. ] if matrix_mautrix_facebook_enabled else [])
  4008. +
  4009. ([
  4010. '^@'+(matrix_mautrix_gmessages_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4011. '^@gmessages_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4012. ] if matrix_mautrix_gmessages_enabled else [])
  4013. +
  4014. ([
  4015. '^@'+(matrix_mautrix_googlechat_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4016. '^@googlechat_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4017. ] if matrix_mautrix_googlechat_enabled else [])
  4018. +
  4019. ([
  4020. '^@'+(matrix_mautrix_hangouts_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4021. '^@hangouts_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4022. ] if matrix_mautrix_hangouts_enabled else [])
  4023. +
  4024. ([
  4025. '^@'+(matrix_mautrix_instagram_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4026. '^@instagram_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4027. ] if matrix_mautrix_instagram_enabled else [])
  4028. +
  4029. ([
  4030. '^@'+(matrix_mautrix_meta_instagram_appservice_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4031. '^@'+(matrix_mautrix_meta_instagram_bridge_username_prefix | default('') | regex_escape)+'[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4032. ] if matrix_mautrix_meta_instagram_enabled else [])
  4033. +
  4034. ([
  4035. '^@'+(matrix_mautrix_meta_messenger_appservice_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4036. '^@'+(matrix_mautrix_meta_messenger_bridge_username_prefix | default('') | regex_escape)+'[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4037. ] if matrix_mautrix_meta_messenger_enabled else [])
  4038. +
  4039. ([
  4040. '^@'+(matrix_mautrix_signal_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4041. '^@signal_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4042. ] if matrix_mautrix_signal_enabled else [])
  4043. +
  4044. ([
  4045. '^@'+(matrix_mautrix_slack_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4046. '^@slack_[a-zA-Z0-9\-]+:'+(matrix_domain | regex_escape)+'$',
  4047. ] if matrix_mautrix_slack_enabled else [])
  4048. +
  4049. ([
  4050. '^@'+(matrix_mautrix_telegram_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4051. '^@telegram_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4052. ] if matrix_mautrix_telegram_enabled else [])
  4053. +
  4054. ([
  4055. '^@'+(matrix_mautrix_twitter_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4056. '^@twitter_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4057. ] if matrix_mautrix_twitter_enabled else [])
  4058. +
  4059. ([
  4060. '^@'+(matrix_mautrix_whatsapp_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4061. '^@whatsapp_[0-9]+:'+(matrix_domain | regex_escape)+'$',
  4062. ] if matrix_mautrix_whatsapp_enabled else [])
  4063. +
  4064. ([
  4065. '^@'+(matrix_mautrix_imessage_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4066. '^@imessage_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4067. ] if matrix_mautrix_wsproxy_enabled else [])
  4068. +
  4069. ([
  4070. '^@_discordpuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4071. ] if matrix_mx_puppet_discord_enabled else [])
  4072. +
  4073. ([
  4074. '^@_groupmepuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4075. ] if matrix_mx_puppet_groupme_enabled else [])
  4076. +
  4077. ([
  4078. '^@_instagrampuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4079. ] if matrix_mx_puppet_instagram_enabled else [])
  4080. +
  4081. ([
  4082. '^@_slackpuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4083. ] if matrix_mx_puppet_slack_enabled else [])
  4084. +
  4085. ([
  4086. '^@_steampuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4087. ] if matrix_mx_puppet_steam_enabled else [])
  4088. +
  4089. ([
  4090. '^@'+(matrix_mx_puppet_twitter_bot_localpart | default('') | regex_escape)+':'+ (matrix_domain | regex_escape)+'$',
  4091. '^@'+(matrix_mx_puppet_twitter_namespace_prefix | default('') | regex_escape)+'[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4092. ] if matrix_mx_puppet_twitter_enabled else [])
  4093. +
  4094. ([
  4095. '^@smsbot:'+(matrix_domain | regex_escape)+'$',
  4096. '^@sms_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4097. ] if matrix_sms_bridge_enabled else [])
  4098. +
  4099. ([
  4100. '^@'+(matrix_wechat_appservice_bot_username | default('') | regex_escape)+':'+(matrix_domain | regex_escape)+'$',
  4101. '^@_wechat_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
  4102. ] if matrix_wechat_enabled else [])
  4103. }}
  4104. ######################################################################
  4105. #
  4106. # /matrix-synapse-admin
  4107. #
  4108. ######################################################################
  4109. ######################################################################
  4110. #
  4111. # matrix-synapse-usage-exporter
  4112. #
  4113. ######################################################################
  4114. matrix_synapse_usage_exporter_enabled: false
  4115. matrix_synapse_usage_exporter_container_network: "{{ matrix_monitoring_container_network }}"
  4116. matrix_synapse_usage_exporter_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [] }}"
  4117. matrix_synapse_usage_exporter_container_labels_traefik_enabled: "{{ matrix_synapse_usage_exporter_proxying_enabled }}"
  4118. matrix_synapse_usage_exporter_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4119. matrix_synapse_usage_exporter_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4120. matrix_synapse_usage_exporter_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4121. ######################################################################
  4122. #
  4123. # /matrix-synapse-usage-exporter
  4124. #
  4125. ######################################################################
  4126. ######################################################################
  4127. #
  4128. # etke/prometheus_node_exporter
  4129. #
  4130. ######################################################################
  4131. prometheus_node_exporter_enabled: false
  4132. prometheus_node_exporter_identifier: matrix-prometheus-node-exporter
  4133. prometheus_node_exporter_base_path: "{{ matrix_base_data_path }}/prometheus-node-exporter"
  4134. prometheus_node_exporter_uid: "{{ matrix_user_uid }}"
  4135. prometheus_node_exporter_gid: "{{ matrix_user_gid }}"
  4136. prometheus_node_exporter_hostname: "{{ matrix_server_fqn_matrix }}"
  4137. prometheus_node_exporter_container_network: "{{ matrix_monitoring_container_network }}"
  4138. prometheus_node_exporter_container_additional_networks: "{{ [matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [] }}"
  4139. prometheus_node_exporter_container_labels_traefik_enabled: "{{ matrix_metrics_exposure_enabled }}"
  4140. prometheus_node_exporter_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4141. prometheus_node_exporter_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4142. prometheus_node_exporter_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4143. prometheus_node_exporter_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  4144. prometheus_node_exporter_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  4145. ######################################################################
  4146. #
  4147. # /etke/prometheus_node_exporter
  4148. #
  4149. ######################################################################
  4150. ######################################################################
  4151. #
  4152. # etke/prometheus_postgres_exporter
  4153. #
  4154. ######################################################################
  4155. prometheus_postgres_exporter_enabled: false
  4156. prometheus_postgres_exporter_identifier: matrix-prometheus-postgres-exporter
  4157. prometheus_postgres_exporter_base_path: "{{ matrix_base_data_path }}/prometheus-postgres-exporter"
  4158. prometheus_postgres_exporter_uid: "{{ matrix_user_uid }}"
  4159. prometheus_postgres_exporter_gid: "{{ matrix_user_gid }}"
  4160. prometheus_postgres_exporter_hostname: "{{ matrix_server_fqn_matrix }}"
  4161. prometheus_postgres_exporter_container_network: "{{ matrix_monitoring_container_network }}"
  4162. prometheus_postgres_exporter_container_additional_networks: |
  4163. {{
  4164. ([postgres_container_network] if (postgres_enabled and prometheus_postgres_exporter_database_hostname == postgres_connection_hostname and prometheus_postgres_exporter_container_network != postgres_container_network) else [])
  4165. +
  4166. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and prometheus_postgres_exporter_container_labels_traefik_enabled else [])
  4167. }}
  4168. prometheus_postgres_exporter_container_labels_traefik_enabled: "{{ matrix_metrics_exposure_enabled }}"
  4169. prometheus_postgres_exporter_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4170. prometheus_postgres_exporter_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4171. prometheus_postgres_exporter_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4172. prometheus_postgres_exporter_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  4173. prometheus_postgres_exporter_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  4174. prometheus_postgres_exporter_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  4175. prometheus_postgres_exporter_database_username: matrix_prometheus_postgres_exporter
  4176. prometheus_postgres_exporter_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'prometheus.pg.db', rounds=655555) | to_uuid }}"
  4177. prometheus_postgres_exporter_database_name: matrix_prometheus_postgres_exporter
  4178. prometheus_postgres_exporter_systemd_required_services_list_auto: |
  4179. {{
  4180. ([postgres_identifier ~ '.service'] if (postgres_enabled and prometheus_postgres_exporter_database_hostname == postgres_connection_hostname) else [])
  4181. }}
  4182. ######################################################################
  4183. #
  4184. # /etke/prometheus_postgres_exporter
  4185. #
  4186. ######################################################################
  4187. ######################################################################
  4188. #
  4189. # matrix-prometheus-nginxlog-exporter
  4190. #
  4191. ######################################################################
  4192. matrix_prometheus_nginxlog_exporter_enabled: false
  4193. matrix_prometheus_nginxlog_exporter_identifier: matrix-prometheus-nginxlog-exporter
  4194. matrix_prometheus_nginxlog_exporter_hostname: "{{ matrix_server_fqn_matrix }}"
  4195. matrix_prometheus_nginxlog_exporter_container_network: "{{ matrix_monitoring_container_network }}"
  4196. matrix_prometheus_nginxlog_exporter_container_additional_networks_auto: |-
  4197. {{
  4198. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_prometheus_nginxlog_exporter_container_labels_traefik_enabled) else [])
  4199. }}
  4200. matrix_prometheus_nginxlog_exporter_container_labels_traefik_enabled: "{{ matrix_metrics_exposure_enabled }}"
  4201. matrix_prometheus_nginxlog_exporter_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4202. matrix_prometheus_nginxlog_exporter_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4203. matrix_prometheus_nginxlog_exporter_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4204. matrix_prometheus_nginxlog_exporter_container_labels_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  4205. matrix_prometheus_nginxlog_exporter_container_labels_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  4206. matrix_prometheus_nginxlog_exporter_config_namespaces_matrix_source_tags_auto: |
  4207. {{
  4208. ([matrix_synapse_reverse_proxy_companion_access_log_syslog_integration_tag] if matrix_synapse_reverse_proxy_companion_access_log_syslog_integration_enabled else [])
  4209. }}
  4210. ######################################################################
  4211. #
  4212. # /matrix-prometheus-nginxlog-exporter
  4213. #
  4214. ######################################################################
  4215. ######################################################################
  4216. #
  4217. # prometheus
  4218. #
  4219. ######################################################################
  4220. prometheus_enabled: false
  4221. prometheus_identifier: matrix-prometheus
  4222. prometheus_base_path: "{{ matrix_base_data_path }}/prometheus"
  4223. prometheus_uid: "{{ matrix_user_uid }}"
  4224. prometheus_gid: "{{ matrix_user_gid }}"
  4225. prometheus_container_network: "{{ matrix_monitoring_container_network }}"
  4226. prometheus_container_additional_networks_auto: |
  4227. {{
  4228. (
  4229. ([prometheus_node_exporter_container_network] if prometheus_self_node_scraper_enabled and prometheus_node_exporter_container_network != prometheus_container_network else [])
  4230. +
  4231. ([matrix_synapse_container_network] if matrix_prometheus_services_connect_scraper_synapse_enabled and matrix_synapse_container_network != prometheus_container_network else [])
  4232. +
  4233. ([prometheus_postgres_exporter_container_network] if matrix_prometheus_services_connect_scraper_postgres_enabled and prometheus_postgres_exporter_container_network != prometheus_container_network else [])
  4234. +
  4235. ([matrix_hookshot_container_network] if matrix_prometheus_services_connect_scraper_hookshot_enabled and matrix_hookshot_container_network != prometheus_container_network else [])
  4236. +
  4237. ([matrix_prometheus_nginxlog_exporter_container_network] if matrix_prometheus_services_connect_scraper_nginxlog_enabled and matrix_prometheus_nginxlog_exporter_container_network != prometheus_container_network else [])
  4238. +
  4239. ([matrix_media_repo_container_network] if matrix_prometheus_services_connect_scraper_media_repo_enabled and matrix_media_repo_container_network != prometheus_container_network else [])
  4240. +
  4241. ([matrix_synapse_usage_exporter_container_network] if matrix_prometheus_services_connect_scraper_synapse_usage_exporter_enabled and matrix_synapse_usage_exporter_container_network != prometheus_container_network else [])
  4242. ) | unique
  4243. }}
  4244. prometheus_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '9090') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  4245. prometheus_config_rule_files_auto: |
  4246. {{
  4247. (['synapse-v2.rules'] if matrix_prometheus_services_connect_synapse_rules_enabled else [])
  4248. }}
  4249. prometheus_self_node_scraper_enabled: "{{ prometheus_node_exporter_enabled }}"
  4250. prometheus_self_node_scraper_static_configs_target: "{{ (prometheus_node_exporter_identifier + ':9100') if prometheus_node_exporter_enabled else '' }}"
  4251. prometheus_config_scrape_configs_auto: |
  4252. {{
  4253. (matrix_prometheus_services_connect_scraper_synapse_configs if matrix_prometheus_services_connect_scraper_synapse_enabled else [])
  4254. +
  4255. (matrix_prometheus_services_connect_scraper_postgres_scrape_configs if matrix_prometheus_services_connect_scraper_postgres_enabled else [])
  4256. +
  4257. (matrix_prometheus_services_connect_scraper_hookshot_scrape_configs if matrix_prometheus_services_connect_scraper_hookshot_enabled else [])
  4258. +
  4259. (matrix_prometheus_services_connect_scraper_nginxlog_scrape_configs if matrix_prometheus_services_connect_scraper_nginxlog_enabled else [])
  4260. +
  4261. (matrix_prometheus_services_connect_scraper_media_repo_scrape_configs if matrix_prometheus_services_connect_scraper_media_repo_enabled else [])
  4262. +
  4263. (matrix_prometheus_services_connect_scraper_synapse_usage_exporter_scrape_configs if matrix_prometheus_services_connect_scraper_synapse_usage_exporter_enabled else [])
  4264. }}
  4265. ######################################################################
  4266. #
  4267. # /prometheus
  4268. #
  4269. ######################################################################
  4270. ######################################################################
  4271. #
  4272. # matrix-prometheus-services-connect
  4273. #
  4274. ######################################################################
  4275. matrix_prometheus_services_connect_synapse_enabled: "{{ prometheus_enabled and matrix_synapse_enabled }}"
  4276. matrix_prometheus_services_connect_synapse_rules_download_synapse_tag: "{{ matrix_synapse_docker_image_tag }}"
  4277. matrix_prometheus_services_connect_synapse_rules_download_dir_path: "{{ prometheus_config_path }}"
  4278. matrix_prometheus_services_connect_synapse_rules_download_owner: "{{ prometheus_uid }}"
  4279. matrix_prometheus_services_connect_synapse_rules_download_group: "{{ prometheus_gid }}"
  4280. matrix_prometheus_services_connect_scraper_synapse_enabled: "{{ matrix_synapse_enabled and matrix_synapse_metrics_enabled }}"
  4281. matrix_prometheus_services_connect_scraper_synapse_main_process_static_configs_target: "matrix-synapse:{{ matrix_synapse_metrics_port }}"
  4282. matrix_prometheus_services_connect_scraper_synapse_workers_enabled_list: "{{ matrix_synapse_workers_enabled_list }}"
  4283. matrix_prometheus_services_connect_scraper_postgres_enabled: "{{ prometheus_postgres_exporter_enabled }}"
  4284. matrix_prometheus_services_connect_scraper_postgres_static_configs_target: "{{ prometheus_postgres_exporter_identifier }}:{{ prometheus_postgres_exporter_port | string }}"
  4285. matrix_prometheus_services_connect_scraper_hookshot_enabled: "{{ matrix_hookshot_enabled and matrix_hookshot_metrics_enabled }}"
  4286. matrix_prometheus_services_connect_scraper_hookshot_static_configs_target: "{{ matrix_hookshot_container_url }}:{{ matrix_hookshot_metrics_port | string }}"
  4287. matrix_prometheus_services_connect_scraper_nginxlog_enabled: "{{ matrix_prometheus_nginxlog_exporter_enabled }}"
  4288. matrix_prometheus_services_connect_scraper_nginxlog_static_configs_target: "{{ matrix_prometheus_nginxlog_exporter_identifier }}:{{ matrix_prometheus_nginxlog_exporter_container_metrics_port | string }}"
  4289. matrix_prometheus_services_connect_scraper_media_repo_enabled: "{{ matrix_media_repo_enabled and matrix_media_repo_metrics_enabled }}"
  4290. matrix_prometheus_services_connect_scraper_media_repo_static_configs_target: "{{ matrix_media_repo_identifier }}:{{ matrix_media_repo_metrics_port }}"
  4291. matrix_prometheus_services_connect_scraper_synapse_usage_exporter_enabled: "{{ matrix_synapse_usage_exporter_enabled }}"
  4292. matrix_prometheus_services_connect_scraper_synapse_usage_exporter_static_configs_target: "{{ matrix_synapse_usage_exporter_identifier }}:{{ matrix_synapse_usage_exporter_container_port | string }}"
  4293. ######################################################################
  4294. #
  4295. # /matrix-prometheus-services-connect
  4296. #
  4297. ######################################################################
  4298. ######################################################################
  4299. #
  4300. # etke/grafana
  4301. #
  4302. ######################################################################
  4303. grafana_enabled: false
  4304. grafana_identifier: matrix-grafana
  4305. grafana_uid: "{{ matrix_user_uid }}"
  4306. grafana_gid: "{{ matrix_user_gid }}"
  4307. grafana_hostname: "{{ matrix_server_fqn_grafana }}"
  4308. grafana_base_path: "{{ matrix_base_data_path }}/grafana"
  4309. grafana_container_network: "{{ matrix_monitoring_container_network }}"
  4310. grafana_container_additional_networks_auto: |
  4311. {{
  4312. (
  4313. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network and grafana_container_labels_traefik_enabled else [])
  4314. +
  4315. ([prometheus_container_network] if prometheus_enabled and prometheus_container_network != grafana_container_network else [])
  4316. ) | unique
  4317. }}
  4318. grafana_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  4319. grafana_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4320. grafana_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4321. grafana_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4322. grafana_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '3000') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  4323. grafana_provisioning_datasources: |
  4324. {{
  4325. ([{
  4326. 'name': (matrix_server_fqn_matrix + ' - Prometheus'),
  4327. 'type': 'prometheus',
  4328. 'access': 'proxy',
  4329. 'url': ('http://' + prometheus_identifier + ':9090'),
  4330. 'jsonData': {
  4331. 'timeInterval': prometheus_config_global_scrape_interval,
  4332. }
  4333. }] if prometheus_enabled else [])
  4334. }}
  4335. grafana_dashboard_download_urls: |
  4336. {{
  4337. (matrix_synapse_grafana_dashboard_urls if matrix_homeserver_implementation == 'synapse' and matrix_synapse_metrics_enabled else [])
  4338. +
  4339. (prometheus_node_exporter_dashboard_urls if prometheus_node_exporter_enabled else [])
  4340. +
  4341. (prometheus_postgres_exporter_dashboard_urls if prometheus_postgres_exporter_enabled else [])
  4342. +
  4343. (matrix_prometheus_nginxlog_exporter_dashboard_urls if matrix_prometheus_nginxlog_exporter_enabled else [])
  4344. +
  4345. (matrix_media_repo_dashboard_urls if matrix_media_repo_metrics_enabled else [])
  4346. +
  4347. (matrix_synapse_usage_exporter_dashboard_urls if matrix_synapse_usage_exporter_enabled else [])
  4348. }}
  4349. grafana_provisioning_dashboard_template_files: |
  4350. {{
  4351. ([{
  4352. 'path': 'roles/custom/matrix-prometheus-nginxlog-exporter/templates/grafana/nginx-proxy.json',
  4353. 'name': 'nginx-proxy.json',
  4354. }] if matrix_prometheus_nginxlog_exporter_enabled else [])
  4355. }}
  4356. grafana_default_home_dashboard_path: |-
  4357. {{
  4358. {
  4359. 'synapse': ('/etc/grafana/dashboards/synapse.json' if matrix_synapse_metrics_enabled and matrix_synapse_metrics_enabled else ('/etc/grafana/dashboards/node-exporter-full.json' if prometheus_node_exporter_enabled else '')),
  4360. 'dendrite': ('/etc/grafana/dashboards/node-exporter-full.json' if prometheus_node_exporter_enabled else ''),
  4361. 'conduit': ('/etc/grafana/dashboards/node-exporter-full.json' if prometheus_node_exporter_enabled else ''),
  4362. }[matrix_homeserver_implementation]
  4363. }}
  4364. ######################################################################
  4365. #
  4366. # /etke/grafana
  4367. #
  4368. ######################################################################
  4369. ######################################################################
  4370. #
  4371. # matrix-registration
  4372. #
  4373. ######################################################################
  4374. matrix_registration_enabled: false
  4375. matrix_registration_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  4376. matrix_registration_hostname: "{{ matrix_server_fqn_matrix }}"
  4377. matrix_registration_path_prefix: /matrix-registration
  4378. matrix_registration_systemd_required_services_list_auto: |
  4379. {{
  4380. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_registration_database_hostname == postgres_connection_hostname) else [])
  4381. }}
  4382. matrix_registration_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
  4383. matrix_registration_container_http_host_bind_port: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ '8767') if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  4384. matrix_registration_container_network: "{{ matrix_addons_container_network }}"
  4385. matrix_registration_container_additional_networks_auto: |-
  4386. {{
  4387. (
  4388. ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
  4389. +
  4390. ([postgres_container_network] if (postgres_enabled and matrix_registration_database_hostname == postgres_connection_hostname and matrix_mautrix_facebook_container_network != postgres_container_network) else [])
  4391. +
  4392. ([matrix_playbook_reverse_proxyable_services_additional_network] if (matrix_playbook_reverse_proxyable_services_additional_network and matrix_registration_container_labels_traefik_enabled) else [])
  4393. ) | unique
  4394. }}
  4395. matrix_registration_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  4396. matrix_registration_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4397. matrix_registration_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4398. matrix_registration_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4399. matrix_registration_riot_instance: "{{ (('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_element) if matrix_client_element_enabled else 'https://element.io/app/' }}"
  4400. matrix_registration_shared_secret: |-
  4401. {{
  4402. {
  4403. 'synapse': matrix_synapse_registration_shared_secret | default (''),
  4404. 'dendrite': matrix_dendrite_client_api_registration_shared_secret | default (''),
  4405. 'conduit': '',
  4406. }[matrix_homeserver_implementation]
  4407. }}
  4408. matrix_registration_server_location: "{{ matrix_addons_homeserver_client_api_url }}"
  4409. matrix_registration_api_validate_certs: "{{ matrix_playbook_ssl_enabled }}"
  4410. # Postgres is the default, except if not using internal Postgres server
  4411. matrix_registration_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
  4412. matrix_registration_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  4413. matrix_registration_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'mx.registr.db', rounds=655555) | to_uuid }}"
  4414. ######################################################################
  4415. #
  4416. # /matrix-registration
  4417. #
  4418. ######################################################################
  4419. ######################################################################
  4420. #
  4421. # matrix-sliding-sync
  4422. #
  4423. ######################################################################
  4424. # We don't enable the sliding sync proxy by default.
  4425. matrix_sliding_sync_enabled: false
  4426. matrix_sliding_sync_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  4427. matrix_sliding_sync_hostname: "{{ matrix_server_fqn_matrix }}"
  4428. matrix_sliding_sync_path_prefix: /sliding-sync
  4429. matrix_sliding_sync_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
  4430. matrix_sliding_sync_container_network: "{{ matrix_homeserver_container_network }}"
  4431. matrix_sliding_sync_container_additional_networks: |
  4432. {{
  4433. (
  4434. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_sliding_sync_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network else [])
  4435. +
  4436. ([] if matrix_homeserver_container_network in ['', matrix_sliding_sync_container_network] else [matrix_homeserver_container_network])
  4437. +
  4438. ([postgres_container_network] if postgres_enabled and postgres_container_network != matrix_sliding_sync_container_network else [])
  4439. ) | unique
  4440. }}
  4441. matrix_sliding_sync_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] }}"
  4442. matrix_sliding_sync_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4443. matrix_sliding_sync_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4444. matrix_sliding_sync_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4445. matrix_sliding_sync_container_labels_public_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  4446. matrix_sliding_sync_container_labels_public_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  4447. matrix_sliding_sync_systemd_required_services_list_auto: |
  4448. {{
  4449. matrix_homeserver_systemd_services_list
  4450. +
  4451. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_sliding_sync_database_hostname == postgres_connection_hostname) else [])
  4452. }}
  4453. matrix_sliding_sync_environment_variable_syncv3_server: "{{ matrix_homeserver_container_url }}"
  4454. matrix_sliding_sync_environment_variable_syncv3_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ss.secret', rounds=655555) | to_uuid }}"
  4455. matrix_sliding_sync_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  4456. matrix_sliding_sync_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'ss.db', rounds=655555) | to_uuid }}"
  4457. matrix_sliding_sync_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  4458. matrix_sliding_sync_metrics_proxying_enabled: "{{ matrix_sliding_sync_metrics_enabled and matrix_metrics_exposure_enabled }}"
  4459. matrix_sliding_sync_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  4460. matrix_sliding_sync_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/sliding-sync"
  4461. #####################################################################
  4462. #
  4463. # /matrix-sliding-sync
  4464. #
  4465. ######################################################################
  4466. ######################################################################
  4467. #
  4468. # matrix-dendrite
  4469. #
  4470. ######################################################################
  4471. matrix_dendrite_enabled: "{{ matrix_homeserver_implementation == 'dendrite' }}"
  4472. matrix_dendrite_hostname: "{{ matrix_server_fqn_matrix }}"
  4473. matrix_dendrite_federation_enabled: "{{ matrix_homeserver_federation_enabled }}"
  4474. matrix_dendrite_container_network: "{{ matrix_homeserver_container_network }}"
  4475. matrix_dendrite_container_additional_networks_auto: |
  4476. {{
  4477. (
  4478. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_dendrite_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network else [])
  4479. +
  4480. ([postgres_container_network] if (postgres_enabled and matrix_dendrite_database_hostname == postgres_connection_hostname and postgres_container_network != matrix_dendrite_container_network) else [])
  4481. ) | unique
  4482. }}
  4483. matrix_dendrite_container_http_host_bind_address: "{{ (matrix_playbook_service_host_bind_interface_prefix ~ matrix_dendrite_http_bind_port | string) if matrix_playbook_service_host_bind_interface_prefix else '' }}"
  4484. matrix_dendrite_container_https_host_bind_address: "{{ '' if not matrix_dendrite_https_bind_port or not matrix_playbook_service_host_bind_interface_prefix else (matrix_playbook_service_host_bind_interface_prefix + matrix_dendrite_https_bind_port | string) }}"
  4485. matrix_dendrite_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] and not matrix_synapse_workers_enabled }}"
  4486. matrix_dendrite_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4487. matrix_dendrite_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4488. matrix_dendrite_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4489. matrix_dendrite_container_labels_public_client_synapse_admin_api_enabled: "{{ matrix_synapse_admin_enabled }}"
  4490. matrix_dendrite_container_labels_public_client_root_redirection_enabled: "{{ matrix_dendrite_container_labels_public_client_root_redirection_url != '' }}"
  4491. matrix_dendrite_container_labels_public_client_root_redirection_url: "{{ (('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_element) if matrix_client_element_enabled else '' }}"
  4492. matrix_dendrite_container_labels_public_federation_api_traefik_hostname: "{{ matrix_server_fqn_matrix_federation }}"
  4493. matrix_dendrite_container_labels_public_federation_api_traefik_entrypoints: "{{ matrix_federation_traefik_entrypoint_name }}"
  4494. matrix_dendrite_container_labels_public_federation_api_traefik_tls: "{{ matrix_federation_traefik_entrypoint_tls }}"
  4495. matrix_dendrite_container_labels_public_metrics_middleware_basic_auth_enabled: "{{ matrix_metrics_exposure_http_basic_auth_enabled }}"
  4496. matrix_dendrite_container_labels_public_metrics_middleware_basic_auth_users: "{{ matrix_metrics_exposure_http_basic_auth_users }}"
  4497. matrix_dendrite_metrics_enabled: "{{ prometheus_enabled or matrix_metrics_exposure_enabled }}"
  4498. matrix_dendrite_metrics_proxying_enabled: "{{ matrix_dendrite_metrics_enabled and matrix_metrics_exposure_enabled }}"
  4499. matrix_dendrite_metrics_proxying_hostname: "{{ matrix_metrics_exposure_hostname }}"
  4500. matrix_dendrite_metrics_proxying_path_prefix: "{{ matrix_metrics_exposure_path_prefix }}/dendrite"
  4501. matrix_dendrite_client_api_registration_shared_secret: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'dendrite.rss', rounds=655555) | to_uuid }}"
  4502. matrix_dendrite_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
  4503. matrix_dendrite_database_password: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'dendrite.db', rounds=655555) | to_uuid }}"
  4504. # Even if TURN doesn't support TLS (it does by default),
  4505. # it doesn't hurt to try a secure connection anyway.
  4506. matrix_dendrite_client_api_turn_uris: |
  4507. {{
  4508. [
  4509. 'turns:' + matrix_server_fqn_matrix + '?transport=udp',
  4510. 'turns:' + matrix_server_fqn_matrix + '?transport=tcp',
  4511. 'turn:' + matrix_server_fqn_matrix + '?transport=udp',
  4512. 'turn:' + matrix_server_fqn_matrix + '?transport=tcp',
  4513. ]
  4514. if matrix_coturn_enabled
  4515. else []
  4516. }}
  4517. matrix_dendrite_client_api_turn_shared_secret: "{{ matrix_coturn_turn_static_auth_secret if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'auth-secret') else '' }}"
  4518. matrix_dendrite_client_api_turn_username: "{{ matrix_coturn_lt_cred_mech_username if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'lt-cred-mech') else '' }}"
  4519. matrix_dendrite_client_api_turn_password: "{{ matrix_coturn_lt_cred_mech_password if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'lt-cred-mech') else '' }}"
  4520. matrix_dendrite_disable_tls_validation: "{{ not matrix_playbook_ssl_enabled }}"
  4521. matrix_dendrite_self_check_validate_certificates: "{{ matrix_playbook_ssl_enabled }}"
  4522. matrix_dendrite_trusted_id_servers: "{{ [matrix_server_fqn_matrix] if matrix_ma1sd_enabled else ['matrix.org', 'vector.im'] }}"
  4523. matrix_dendrite_systemd_required_services_list_auto: |
  4524. {{
  4525. ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_dendrite_database_hostname == postgres_connection_hostname) else [])
  4526. +
  4527. (['matrix-goofys.service'] if matrix_s3_media_store_enabled else [])
  4528. }}
  4529. matrix_dendrite_systemd_wanted_services_list_auto: |
  4530. {{
  4531. (['matrix-coturn.service'] if matrix_coturn_enabled else [])
  4532. }}
  4533. matrix_dendrite_container_extra_arguments_auto: "{{ matrix_homeserver_container_extra_arguments_auto }}"
  4534. matrix_dendrite_app_service_config_files_auto: "{{ matrix_homeserver_app_service_config_files_auto }}"
  4535. ######################################################################
  4536. #
  4537. # /matrix-dendrite
  4538. #
  4539. ######################################################################
  4540. ######################################################################
  4541. #
  4542. # matrix-conduit
  4543. #
  4544. ######################################################################
  4545. matrix_conduit_enabled: "{{ matrix_homeserver_implementation == 'conduit' }}"
  4546. matrix_conduit_hostname: "{{ matrix_server_fqn_matrix }}"
  4547. matrix_conduit_allow_federation: "{{ matrix_homeserver_federation_enabled }}"
  4548. matrix_conduit_container_network: "{{ matrix_homeserver_container_network }}"
  4549. matrix_conduit_container_additional_networks_auto: |
  4550. {{
  4551. (
  4552. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_conduit_container_labels_traefik_enabled and matrix_playbook_reverse_proxyable_services_additional_network else [])
  4553. ) | unique
  4554. }}
  4555. matrix_conduit_container_labels_traefik_enabled: "{{ matrix_playbook_reverse_proxy_type in ['playbook-managed-traefik', 'other-traefik-container'] and not matrix_synapse_workers_enabled }}"
  4556. matrix_conduit_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4557. matrix_conduit_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4558. matrix_conduit_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4559. matrix_conduit_container_labels_public_client_root_redirection_enabled: "{{ matrix_conduit_container_labels_public_client_root_redirection_url != '' }}"
  4560. matrix_conduit_container_labels_public_client_root_redirection_url: "{{ (('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_element) if matrix_client_element_enabled else '' }}"
  4561. matrix_conduit_container_labels_public_federation_api_traefik_hostname: "{{ matrix_server_fqn_matrix_federation }}"
  4562. matrix_conduit_container_labels_public_federation_api_traefik_entrypoints: "{{ matrix_federation_traefik_entrypoint_name }}"
  4563. matrix_conduit_container_labels_public_federation_api_traefik_tls: "{{ matrix_federation_traefik_entrypoint_tls }}"
  4564. matrix_conduit_container_labels_internal_client_api_enabled: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled }}"
  4565. matrix_conduit_container_labels_internal_client_api_traefik_entrypoints: "{{ matrix_playbook_internal_matrix_client_api_traefik_entrypoint_name }}"
  4566. matrix_conduit_turn_uris: |
  4567. {{
  4568. ([
  4569. 'turns:' + matrix_server_fqn_matrix + '?transport=udp',
  4570. 'turns:' + matrix_server_fqn_matrix + '?transport=tcp',
  4571. ] if matrix_coturn_enabled and matrix_coturn_tls_enabled else [])
  4572. +
  4573. ([
  4574. 'turn:' + matrix_server_fqn_matrix + '?transport=udp',
  4575. 'turn:' + matrix_server_fqn_matrix + '?transport=tcp',
  4576. ] if matrix_coturn_enabled else [])
  4577. }}
  4578. matrix_conduit_turn_secret: "{{ matrix_coturn_turn_static_auth_secret if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'auth-secret') else '' }}"
  4579. matrix_conduit_turn_username: "{{ matrix_coturn_lt_cred_mech_username if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'lt-cred-mech') else '' }}"
  4580. matrix_conduit_turn_password: "{{ matrix_coturn_lt_cred_mech_password if (matrix_coturn_enabled and matrix_coturn_authentication_method == 'lt-cred-mech') else '' }}"
  4581. ######################################################################
  4582. #
  4583. # /matrix-conduit
  4584. #
  4585. ######################################################################
  4586. ######################################################################
  4587. #
  4588. # matrix-user-creator
  4589. #
  4590. ######################################################################
  4591. matrix_user_creator_users_auto: |
  4592. {{
  4593. ([{
  4594. 'username': matrix_bot_matrix_registration_bot_matrix_user_id_localpart,
  4595. 'initial_password': matrix_bot_matrix_registration_bot_bot_password,
  4596. 'initial_type': 'admin',
  4597. }] if matrix_bot_matrix_registration_bot_enabled else [])
  4598. +
  4599. ([{
  4600. 'username': matrix_bot_baibot_config_user_mxid_localpart,
  4601. 'initial_password': matrix_bot_baibot_config_user_password,
  4602. 'initial_type': 'bot',
  4603. }] if matrix_bot_baibot_enabled else [])
  4604. +
  4605. ([{
  4606. 'username': matrix_bot_chatgpt_matrix_bot_username_localpart,
  4607. 'initial_password': matrix_bot_chatgpt_matrix_bot_password,
  4608. 'initial_type': 'bot',
  4609. }] if matrix_bot_chatgpt_enabled and matrix_bot_chatgpt_matrix_bot_password | length > 0 else [])
  4610. +
  4611. ([{
  4612. 'username': matrix_bot_matrix_reminder_bot_matrix_user_id_localpart,
  4613. 'initial_password': matrix_bot_matrix_reminder_bot_matrix_user_password,
  4614. 'initial_type': 'bot',
  4615. }] if matrix_bot_matrix_reminder_bot_enabled else [])
  4616. +
  4617. ([{
  4618. 'username': matrix_bot_honoroit_login,
  4619. 'initial_password': matrix_bot_honoroit_password,
  4620. 'initial_type': 'bot',
  4621. }] if matrix_bot_honoroit_enabled else [])
  4622. +
  4623. ([{
  4624. 'username': matrix_postmoogle_login,
  4625. 'initial_password': matrix_postmoogle_password,
  4626. 'initial_type': 'bot',
  4627. }] if matrix_postmoogle_enabled else [])
  4628. +
  4629. ([{
  4630. 'username': matrix_bot_buscarron_login,
  4631. 'initial_password': matrix_bot_buscarron_password,
  4632. 'initial_type': 'bot',
  4633. }] if matrix_bot_buscarron_enabled else [])
  4634. +
  4635. ([{
  4636. 'username': matrix_bot_maubot_login,
  4637. 'initial_password': matrix_bot_maubot_initial_password,
  4638. 'initial_type': 'bot',
  4639. }] if matrix_bot_maubot_enabled else [])
  4640. }}
  4641. ######################################################################
  4642. #
  4643. # /matrix-user-creator
  4644. #
  4645. ######################################################################
  4646. ######################################################################
  4647. #
  4648. # matrix-user-verification-service
  4649. #
  4650. ######################################################################
  4651. matrix_user_verification_service_enabled: false
  4652. matrix_user_verification_service_systemd_required_services_list: |
  4653. {{
  4654. [devture_systemd_docker_base_docker_service_name]
  4655. +
  4656. (['matrix-' + matrix_homeserver_implementation + '.service'])
  4657. }}
  4658. matrix_user_verification_service_container_network: "{{ matrix_addons_container_network }}"
  4659. matrix_user_verification_service_container_additional_networks: |
  4660. {{
  4661. (
  4662. ([matrix_playbook_reverse_proxyable_services_additional_network] if matrix_playbook_reverse_proxyable_services_additional_network else [])
  4663. +
  4664. ([matrix_homeserver_container_network] if matrix_homeserver_container_network != matrix_user_verification_service_container_network else [])
  4665. ) | unique
  4666. }}
  4667. # If Jitsi is managed by this playbook we can use the docker network - no need to expose a port.
  4668. # If Jitsi is not managed by this playbook, or you otherwise have a need for it, you can expose
  4669. # matrix-user-verfification-services's client-server port to port 3003.
  4670. # By default Matrix-User-Verification-Service binds to port 3000, which collides with grafana, therefore this uses port 3003.
  4671. matrix_user_verification_service_container_http_host_bind_port: "{{ '' if (jitsi_enabled | bool and jitsi_enable_auth | bool and jitsi_auth_type == 'matrix') else matrix_playbook_service_host_bind_interface_prefix ~ '3003' }}"
  4672. # URL exposed in the docker network
  4673. matrix_user_verification_service_container_url: "http://{{ matrix_user_verification_service_container_name }}:3000"
  4674. matrix_user_verification_service_uvs_homeserver_url: "{{ matrix_addons_homeserver_client_api_url }}"
  4675. # We connect via the container network (private IPs), so we need to disable IP checks
  4676. matrix_user_verification_service_uvs_disable_ip_blacklist: "{{'true' if matrix_synapse_enabled else 'false'}}"
  4677. matrix_user_verification_service_uvs_auth_token: "{{ '%s' | format(matrix_homeserver_generic_secret_key) | password_hash('sha512', 'uvs.auth.token', rounds=655555) | to_uuid }}"
  4678. ######################################################################
  4679. #
  4680. # /matrix-user-verification-service
  4681. #
  4682. ######################################################################
  4683. ########################################################################
  4684. # #
  4685. # matrix-static-files #
  4686. # #
  4687. ########################################################################
  4688. matrix_static_files_enabled: true
  4689. matrix_static_files_container_network: "{{ (matrix_static_files_identifier if matrix_playbook_reverse_proxy_type == 'none' else matrix_playbook_reverse_proxy_container_network) }}"
  4690. matrix_static_files_container_labels_traefik_enabled: "{{ matrix_playbook_traefik_labels_enabled }}"
  4691. matrix_static_files_container_labels_traefik_docker_network: "{{ matrix_playbook_reverse_proxyable_services_additional_network }}"
  4692. matrix_static_files_container_labels_traefik_entrypoints: "{{ traefik_entrypoint_primary }}"
  4693. matrix_static_files_container_labels_traefik_tls_certResolver: "{{ traefik_certResolver_primary }}"
  4694. matrix_static_files_container_labels_well_known_matrix_endpoint_traefik_hostname: "{{ matrix_server_fqn_matrix }}"
  4695. # Base domain serving is not enabled by default (see `matrix_static_files_container_labels_base_domain_enabled`),
  4696. # but we pass the hostname, so that enabling it is easy.
  4697. matrix_static_files_container_labels_base_domain_traefik_hostname: "{{ matrix_domain }}"
  4698. # If we're not serving a static webpage, serve a redirect instead of a 404.
  4699. matrix_static_files_container_labels_base_domain_root_path_redirection_enabled: "{{ not matrix_static_files_file_index_html_enabled }}"
  4700. matrix_static_files_container_labels_base_domain_root_path_redirection_url: "{{ ('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_matrix }}"
  4701. matrix_static_files_file_matrix_client_property_io_element_jitsi_preferred_domain: "{{ matrix_server_fqn_jitsi if jitsi_enabled else '' }}"
  4702. matrix_static_files_file_matrix_client_property_org_matrix_msc3575_proxy_url: "{{ matrix_homeserver_sliding_sync_url }}"
  4703. matrix_static_files_file_matrix_client_property_org_matrix_msc2965_authentication_enabled: "{{ matrix_authentication_service_enabled }}"
  4704. matrix_static_files_file_matrix_client_property_org_matrix_msc2965_authentication_issuer: "{{ matrix_authentication_service_config_http_issuer if matrix_authentication_service_enabled else '' }}"
  4705. matrix_static_files_file_matrix_client_property_org_matrix_msc2965_authentication_account: "{{ matrix_authentication_service_account_management_url }}"
  4706. matrix_static_files_file_matrix_client_property_m_tile_server_entries_enabled: "{{ matrix_client_element_location_sharing_enabled }}"
  4707. matrix_static_files_file_matrix_client_property_m_tile_server_map_style_url: "{{ ('https://' if matrix_playbook_ssl_enabled else 'http://') + matrix_server_fqn_element }}/map_style.json"
  4708. # We set this regardless of whether synapse-admin is enabled, because people may wish to use a hosted (externally) synapse-admin installation and still have it auto-configured.
  4709. # See: https://github.com/etkecc/synapse-admin/pull/126
  4710. matrix_static_files_file_matrix_client_property_cc_etke_synapse_admin_auto: "{{ matrix_synapse_admin_configuration if matrix_homeserver_implementation == 'synapse' else {} }}"
  4711. matrix_static_files_file_matrix_server_property_m_server: "{{ matrix_server_fqn_matrix_federation }}:{{ matrix_federation_public_port }}"
  4712. matrix_static_files_scheme: "{{ 'https' if matrix_playbook_ssl_enabled else 'http' }}"
  4713. matrix_static_files_self_check_hostname_matrix: "{{ matrix_server_fqn_matrix }}"
  4714. matrix_static_files_self_check_hostname_identity: "{{ matrix_domain }}"
  4715. ########################################################################
  4716. # #
  4717. # /matrix-static-files #
  4718. # #
  4719. ########################################################################
  4720. ########################################################################
  4721. # #
  4722. # com.devture.ansible.role.container_socket_proxy #
  4723. # #
  4724. ########################################################################
  4725. devture_container_socket_proxy_enabled: "{{ matrix_playbook_reverse_proxy_type == 'playbook-managed-traefik' }}"
  4726. devture_container_socket_proxy_identifier: matrix-container-socket-proxy
  4727. devture_container_socket_proxy_base_path: "{{ matrix_base_data_path }}/container-socket-proxy"
  4728. devture_container_socket_proxy_uid: "{{ matrix_user_uid }}"
  4729. devture_container_socket_proxy_gid: "{{ matrix_user_gid }}"
  4730. # Traefik requires read access to the containers APIs to do its job
  4731. devture_container_socket_proxy_api_containers_enabled: true
  4732. ########################################################################
  4733. # #
  4734. # /com.devture.ansible.role.container_socket_proxy #
  4735. # #
  4736. ########################################################################
  4737. ########################################################################
  4738. # #
  4739. # traefik #
  4740. # #
  4741. ########################################################################
  4742. traefik_enabled: "{{ matrix_playbook_reverse_proxy_type == 'playbook-managed-traefik' }}"
  4743. traefik_identifier: matrix-traefik
  4744. traefik_base_path: "{{ matrix_base_data_path }}/traefik"
  4745. traefik_uid: "{{ matrix_user_uid }}"
  4746. traefik_gid: "{{ matrix_user_gid }}"
  4747. # It's common for setups to deal with large file uploads which may take longer than the default readTimeout (60s).
  4748. # This override (for the `web` entrypoint) also cascades to overriding the `web-secure` entrypoint and the `matrix-federation` entrypoint.
  4749. traefik_config_entrypoint_web_transport_respondingTimeouts_readTimeout: 300s
  4750. traefik_additional_entrypoints_auto: |
  4751. {{
  4752. ([matrix_playbook_public_matrix_federation_api_traefik_entrypoint_definition] if matrix_playbook_public_matrix_federation_api_traefik_entrypoint_enabled else [])
  4753. +
  4754. ([matrix_playbook_internal_matrix_client_api_traefik_entrypoint_definition] if matrix_playbook_internal_matrix_client_api_traefik_entrypoint_enabled else [])
  4755. }}
  4756. traefik_config_providers_docker_endpoint: "{{ devture_container_socket_proxy_endpoint if devture_container_socket_proxy_enabled else 'unix:///var/run/docker.sock' }}"
  4757. traefik_container_additional_networks_auto: |
  4758. {{
  4759. ([devture_container_socket_proxy_container_network] if devture_container_socket_proxy_enabled else [])
  4760. }}
  4761. traefik_systemd_required_services_list: |
  4762. {{
  4763. ([devture_systemd_docker_base_docker_service_name])
  4764. +
  4765. ([devture_container_socket_proxy_identifier + '.service'] if devture_container_socket_proxy_enabled else [])
  4766. }}
  4767. ########################################################################
  4768. # #
  4769. # /traefik #
  4770. # #
  4771. ########################################################################
  4772. ########################################################################
  4773. # #
  4774. # traefik_certs_dumper #
  4775. # #
  4776. ########################################################################
  4777. traefik_certs_dumper_enabled: "{{ (matrix_playbook_reverse_proxy_type == 'playbook-managed-traefik' and traefik_config_entrypoint_web_secure_enabled and traefik_config_certificatesResolvers_acme_enabled) or matrix_playbook_reverse_proxy_type == 'other-traefik-container' }}"
  4778. traefik_certs_dumper_identifier: matrix-traefik-certs-dumper
  4779. traefik_certs_dumper_base_path: "{{ matrix_base_data_path }}/traefik-certs-dumper"
  4780. traefik_certs_dumper_uid: "{{ matrix_user_uid }}"
  4781. traefik_certs_dumper_gid: "{{ matrix_user_gid }}"
  4782. traefik_certs_dumper_ssl_dir_path: "{{ traefik_ssl_dir_path if traefik_enabled else '' }}"
  4783. ########################################################################
  4784. # #
  4785. # /traefik_certs_dumper #
  4786. # #
  4787. ########################################################################