Matrix Docker Ansible eploy
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

249 строки
14 KiB

  1. # SPDX-FileCopyrightText: 2026 MDAD project contributors
  2. # SPDX-FileCopyrightText: 2026 Jason LaGuidice
  3. #
  4. # SPDX-License-Identifier: AGPL-3.0-or-later
  5. ---
  6. # matrix-bridge-rustpush is a Matrix <-> iMessage bridge using RustPush
  7. # Project source code URL: https://github.com/jasonlaguidice/imessage
  8. matrix_bridge_rustpush_enabled: false
  9. matrix_bridge_rustpush_container_image_self_build: false
  10. matrix_bridge_rustpush_container_image_self_build_repo: "https://github.com/jasonlaguidice/imessage.git"
  11. matrix_bridge_rustpush_container_image_self_build_repo_version: "{{ 'master' if matrix_bridge_rustpush_version == 'latest' else matrix_bridge_rustpush_version }}"
  12. # renovate: datasource=docker depName=ghcr.io/jasonlaguidice/imessage
  13. matrix_bridge_rustpush_version: v0.0.3
  14. matrix_bridge_rustpush_container_image: "{{ matrix_bridge_rustpush_container_image_registry_prefix }}jasonlaguidice/imessage:{{ matrix_bridge_rustpush_version }}"
  15. matrix_bridge_rustpush_container_image_registry_prefix: "{{ 'localhost/' if matrix_bridge_rustpush_container_image_self_build else matrix_bridge_rustpush_container_image_registry_prefix_upstream }}"
  16. matrix_bridge_rustpush_container_image_registry_prefix_upstream: "{{ matrix_bridge_rustpush_container_image_registry_prefix_upstream_default }}"
  17. matrix_bridge_rustpush_container_image_registry_prefix_upstream_default: "ghcr.io/"
  18. matrix_bridge_rustpush_base_path: "{{ matrix_base_data_path }}/matrix-rustpush-bridge"
  19. matrix_bridge_rustpush_config_path: "{{ matrix_bridge_rustpush_base_path }}/config"
  20. matrix_bridge_rustpush_data_path: "{{ matrix_bridge_rustpush_base_path }}/data"
  21. matrix_bridge_rustpush_container_src_files_path: "{{ matrix_bridge_rustpush_base_path }}/docker-src"
  22. matrix_bridge_rustpush_homeserver_address: ""
  23. # Whether asynchronous uploads via MSC2246 should be enabled for media.
  24. matrix_bridge_rustpush_homeserver_async_media: false
  25. matrix_bridge_rustpush_homeserver_domain: '{{ matrix_domain }}'
  26. matrix_bridge_rustpush_appservice_address: 'http://matrix-rustpush-bridge:8081'
  27. matrix_bridge_rustpush_msc4190_enabled: "{{ matrix_bridges_msc4190_enabled }}"
  28. matrix_bridge_rustpush_self_sign_enabled: "{{ matrix_bridges_self_sign_enabled }}"
  29. # A public address that external services can use to reach this appservice.
  30. matrix_bridge_rustpush_appservice_public_address: ''
  31. # Displayname template for iMessage contacts.
  32. # Available variables: {{.FirstName}}, {{.LastName}}, {{.Nickname}},
  33. # {{.Phone}}, {{.Email}}, {{.ID}}
  34. matrix_bridge_rustpush_network_displayname_template: "{% raw %}{{if .FirstName}}{{.FirstName}}{{if .LastName}} {{.LastName}}{{end}}{{else if .Nickname}}{{.Nickname}}{{else if .Phone}}{{.Phone}}{{else if .Email}}{{.Email}}{{else}}{{.ID}}{{end}} (iMessage){% endraw %}"
  35. matrix_bridge_rustpush_cloudkit_backfill: true
  36. matrix_bridge_rustpush_video_transcoding: true
  37. matrix_bridge_rustpush_heic_conversion: true
  38. matrix_bridge_rustpush_disable_facetime: false
  39. matrix_bridge_rustpush_statuskit_notifications: false
  40. matrix_bridge_rustpush_statuskit_share_on_startup: true
  41. # Only takes effect when `matrix_bridge_rustpush_statuskit_notifications` is true.
  42. # - topic: sets the contact's DM room topic to their Focus/DND state (e.g. "🔕 Do Not Disturb"), clearing it when available.
  43. # - notice: posts a silent m.notice instead (legacy behavior).
  44. # Group chats always use `notice`, regardless of this setting.
  45. matrix_bridge_rustpush_statuskit_notification_style: topic
  46. matrix_bridge_rustpush_bridge_command_prefix: "!im"
  47. matrix_bridge_rustpush_bridge_permissions: |
  48. {{
  49. {matrix_bridge_rustpush_homeserver_domain: 'user'}
  50. | combine({matrix_admin: 'admin'} if matrix_admin else {})
  51. }}
  52. matrix_bridge_rustpush_container_network: ""
  53. matrix_bridge_rustpush_container_additional_networks: "{{ matrix_bridge_rustpush_container_additional_networks_auto + matrix_bridge_rustpush_container_additional_networks_custom }}"
  54. matrix_bridge_rustpush_container_additional_networks_auto: []
  55. matrix_bridge_rustpush_container_additional_networks_custom: []
  56. # matrix_bridge_rustpush_container_labels_traefik_enabled controls whether labels to assist a Traefik reverse-proxy will be attached to the container.
  57. # See `../templates/labels.j2` for details.
  58. #
  59. # To inject your own other container labels, see `matrix_bridge_rustpush_container_labels_additional_labels`.
  60. matrix_bridge_rustpush_container_labels_traefik_enabled: true
  61. matrix_bridge_rustpush_container_labels_traefik_docker_network: "{{ matrix_bridge_rustpush_container_network }}"
  62. matrix_bridge_rustpush_container_labels_traefik_entrypoints: web-secure
  63. matrix_bridge_rustpush_container_labels_traefik_tls: "{{ matrix_bridge_rustpush_container_labels_traefik_entrypoints != 'web' }}"
  64. matrix_bridge_rustpush_container_labels_traefik_tls_certResolver: default # noqa var-naming
  65. # Whether this bridge's HTTP API (including the provisioning API) is exposed at a
  66. # public path via Traefik. Disabled by default. When enabled, requests to
  67. # https://<matrix_bridge_rustpush_exposure_hostname><matrix_bridge_rustpush_exposure_path_prefix>/...
  68. # are forwarded to the bridge with that path prefix stripped.
  69. matrix_bridge_rustpush_exposure_enabled: false
  70. matrix_bridge_rustpush_exposure_hostname: ''
  71. matrix_bridge_rustpush_exposure_path_prefix: ''
  72. matrix_bridge_rustpush_container_labels_exposure_enabled: "{{ matrix_bridge_rustpush_exposure_enabled }}"
  73. matrix_bridge_rustpush_container_labels_exposure_traefik_rule: "Host(`{{ matrix_bridge_rustpush_exposure_hostname }}`) && PathPrefix(`{{ matrix_bridge_rustpush_exposure_path_prefix }}`)"
  74. matrix_bridge_rustpush_container_labels_exposure_traefik_priority: 0
  75. matrix_bridge_rustpush_container_labels_exposure_traefik_entrypoints: "{{ matrix_bridge_rustpush_container_labels_traefik_entrypoints }}"
  76. matrix_bridge_rustpush_container_labels_exposure_traefik_tls: "{{ matrix_bridge_rustpush_container_labels_exposure_traefik_entrypoints != 'web' }}"
  77. matrix_bridge_rustpush_container_labels_exposure_traefik_tls_certResolver: "{{ matrix_bridge_rustpush_container_labels_traefik_tls_certResolver }}" # noqa var-naming
  78. # matrix_bridge_rustpush_container_labels_additional_labels contains a multiline string with additional labels to add to the container label file.
  79. # See `../templates/labels.j2` for details.
  80. #
  81. # Example:
  82. # matrix_bridge_rustpush_container_labels_additional_labels: |
  83. # my.label=1
  84. # another.label="here"
  85. matrix_bridge_rustpush_container_labels_additional_labels: ''
  86. # A list of extra arguments to pass to the container
  87. matrix_bridge_rustpush_container_extra_arguments: []
  88. # Override the Rust log filter passed to the bridge container via RUST_LOG.
  89. # Leave empty to use the bridge's built-in default
  90. # ("warn,rustpush=warn,rustpushgo=info,open_absinthe=info").
  91. #
  92. # Useful values:
  93. # "warn,rustpushgo=info,open_absinthe=debug" # NAC emulator diagnostics (_enc field sizes, etc.)
  94. # "warn,rustpushgo=info,open_absinthe=debug,rustpush=info" # + upstream rustpush internals
  95. # "debug" # everything (very chatty)
  96. #
  97. # The open_absinthe crate logs NAC hardware-key diagnostics at INFO and emulator
  98. # state at DEBUG. These are suppressed by default to reduce log noise.
  99. matrix_bridge_rustpush_rust_log: ""
  100. # List of systemd services that matrix-rustpush-bridge.service depends on.
  101. matrix_bridge_rustpush_systemd_required_services_list: "{{ matrix_bridge_rustpush_systemd_required_services_list_default + matrix_bridge_rustpush_systemd_required_services_list_auto + matrix_bridge_rustpush_systemd_required_services_list_custom }}"
  102. matrix_bridge_rustpush_systemd_required_services_list_default: "{{ [devture_systemd_docker_base_docker_service_name] if devture_systemd_docker_base_docker_service_name else [] }}"
  103. matrix_bridge_rustpush_systemd_required_services_list_auto: []
  104. matrix_bridge_rustpush_systemd_required_services_list_custom: []
  105. # List of systemd services that matrix-rustpush-bridge.service wants
  106. matrix_bridge_rustpush_systemd_wanted_services_list: []
  107. matrix_bridge_rustpush_appservice_token: ''
  108. matrix_bridge_rustpush_homeserver_token: ''
  109. # Whether or not created rooms should have federation enabled.
  110. # If false, created portal rooms will never be federated.
  111. matrix_bridge_rustpush_matrix_federate_rooms: false
  112. # Database-related configuration fields.
  113. #
  114. # To use Postgres:
  115. # - adjust your database credentials via the `matrix_bridge_rustpush_postgres_*` variables
  116. matrix_bridge_rustpush_database_engine: 'postgres'
  117. matrix_bridge_rustpush_database_username: 'matrix_rustpush_bridge'
  118. matrix_bridge_rustpush_database_password: 'some-password'
  119. matrix_bridge_rustpush_database_hostname: ''
  120. matrix_bridge_rustpush_database_port: 5432
  121. matrix_bridge_rustpush_database_name: 'matrix_rustpush_bridge'
  122. matrix_bridge_rustpush_database_sslmode: disable
  123. matrix_bridge_rustpush_database_connection_string: 'postgres://{{ matrix_bridge_rustpush_database_username }}:{{ matrix_bridge_rustpush_database_password }}@{{ matrix_bridge_rustpush_database_hostname }}:{{ matrix_bridge_rustpush_database_port }}/{{ matrix_bridge_rustpush_database_name }}?sslmode={{ matrix_bridge_rustpush_database_sslmode }}'
  124. matrix_bridge_rustpush_database_uri: "{{
  125. {
  126. 'postgres': matrix_bridge_rustpush_database_connection_string,
  127. }[matrix_bridge_rustpush_database_engine]
  128. }}"
  129. matrix_bridge_rustpush_double_puppet_secrets: "{{ matrix_bridge_rustpush_double_puppet_secrets_auto | combine(matrix_bridge_rustpush_double_puppet_secrets_custom) }}"
  130. matrix_bridge_rustpush_double_puppet_secrets_auto: {}
  131. matrix_bridge_rustpush_double_puppet_secrets_custom: {}
  132. matrix_bridge_rustpush_appservice_bot_username: rustpushbot
  133. matrix_bridge_rustpush_appservice_bot_displayname: RustPush bridge bot
  134. matrix_bridge_rustpush_appservice_bot_avatar: ''
  135. # Localpart template for MXIDs of remote (iMessage) users.
  136. # The `{{.}}` placeholder expands to the iMessage handle (phone/email).
  137. matrix_bridge_rustpush_appservice_username_template: "{% raw %}rustpush_{{.}}{% endraw %}"
  138. # Backfill is disabled by default because Linux Docker cannot access chat.db.
  139. # On macOS with Full Disk Access, this can be set to true.
  140. matrix_bridge_rustpush_backfill_enabled: false
  141. # Maximum number of messages to backfill in empty rooms
  142. matrix_bridge_rustpush_backfill_max_initial_messages: 50
  143. # Maximum number of missed messages to backfill after bridge restarts
  144. matrix_bridge_rustpush_backfill_max_catchup_messages: 500
  145. # How many days back to look for chats during initial sync.
  146. # Default in upstream is 365 (1 year). Set to 0 to disable.
  147. matrix_bridge_rustpush_initial_sync_days: 365
  148. # Shared secret for authentication of provisioning API requests.
  149. # If set to "disable", the provisioning API will be disabled.
  150. matrix_bridge_rustpush_provisioning_shared_secret: disable
  151. # Minimum severity of journal log messages.
  152. # Valid values: fatal, error, warn, info, debug, trace
  153. matrix_bridge_rustpush_logging_level: 'warn'
  154. # Default configuration template which covers the generic use case.
  155. # You can customize it by controlling the various variables inside it.
  156. #
  157. # For a more advanced customization, you can extend the default (see `matrix_bridge_rustpush_configuration_extension_yaml`)
  158. # or completely replace this variable with your own template.
  159. matrix_bridge_rustpush_configuration_yaml: "{{ lookup('template', 'templates/config.yaml.j2') }}"
  160. matrix_bridge_rustpush_configuration_extension_yaml: |
  161. # Your custom YAML configuration goes here.
  162. # This configuration extends the default starting configuration (`matrix_bridge_rustpush_configuration_yaml`).
  163. #
  164. # You can override individual variables from the default configuration, or introduce new ones.
  165. #
  166. # If you need something more special, you can take full control by
  167. # completely redefining `matrix_bridge_rustpush_configuration_yaml`.
  168. matrix_bridge_rustpush_configuration_extension: "{{ matrix_bridge_rustpush_configuration_extension_yaml | from_yaml if matrix_bridge_rustpush_configuration_extension_yaml | from_yaml is mapping else {} }}"
  169. # Holds the final configuration (a combination of the default and its extension).
  170. # You most likely don't need to touch this variable. Instead, see `matrix_bridge_rustpush_configuration_yaml`.
  171. matrix_bridge_rustpush_configuration: "{{ matrix_bridge_rustpush_configuration_yaml | from_yaml | combine(matrix_bridge_rustpush_configuration_extension, recursive=True) }}"
  172. matrix_bridge_rustpush_registration_yaml: |
  173. id: rustpush-bridge
  174. as_token: "{{ matrix_bridge_rustpush_appservice_token }}"
  175. hs_token: "{{ matrix_bridge_rustpush_homeserver_token }}"
  176. namespaces:
  177. users:
  178. - exclusive: true
  179. regex: '^@rustpush_.+:{{ matrix_bridge_rustpush_homeserver_domain | regex_escape }}$'
  180. - exclusive: true
  181. regex: '^@{{ matrix_bridge_rustpush_appservice_bot_username | regex_escape }}:{{ matrix_bridge_rustpush_homeserver_domain | regex_escape }}$'
  182. url: {{ matrix_bridge_rustpush_appservice_address }}
  183. sender_localpart: _bot_{{ matrix_bridge_rustpush_appservice_bot_username }}
  184. rate_limited: false
  185. de.sorunome.msc2409.push_ephemeral: true
  186. receive_ephemeral: true
  187. io.element.msc4190: {{ matrix_bridge_rustpush_msc4190_enabled | to_json }}
  188. matrix_bridge_rustpush_registration: "{{ matrix_bridge_rustpush_registration_yaml | from_yaml }}"
  189. # Enable End-to-bridge encryption
  190. matrix_bridge_rustpush_bridge_encryption_allow: "{{ matrix_bridges_encryption_enabled }}"
  191. matrix_bridge_rustpush_bridge_encryption_default: "{{ matrix_bridges_encryption_default }}"
  192. matrix_bridge_rustpush_bridge_encryption_require: false
  193. matrix_bridge_rustpush_bridge_encryption_appservice: false
  194. matrix_bridge_rustpush_bridge_encryption_key_sharing_allow: "{{ matrix_bridge_rustpush_bridge_encryption_allow }}"
  195. matrix_bridge_rustpush_bridge_encryption_pickle_key: mautrix.bridge.e2ee
  196. # matrix_bridge_rustpush_restart_necessary controls whether the service
  197. # will be restarted (when true) or merely started (when false) by the
  198. # systemd service manager role (when conditional restart is enabled).
  199. #
  200. # This value is automatically computed during installation based on whether
  201. # any configuration files, the systemd service file, or the container image changed.
  202. # The default of `false` means "no restart needed" — appropriate when the role's
  203. # installation tasks haven't run (e.g., due to --tags skipping them).
  204. matrix_bridge_rustpush_restart_necessary: false