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.
 
 
 

209 rivejä
9.8 KiB

  1. {#
  2. SPDX-FileCopyrightText: 2022 MDAD Team and contributors
  3. SPDX-License-Identifier: AGPL-3.0-or-later
  4. #}
  5. #jinja2: lstrip_blocks: "True"
  6. # Homeserver details
  7. homeserver:
  8. # The address that this appservice can use to connect to the homeserver.
  9. address: {{ matrix_mautrix_twitter_homeserver_address }}
  10. # The domain of the homeserver (for MXIDs, etc).
  11. domain: {{ matrix_mautrix_twitter_homeserver_domain }}
  12. # Whether or not to verify the SSL certificate of the homeserver.
  13. # Only applies if address starts with https://
  14. verify_ssl: true
  15. asmux: false
  16. # Application service host/registration related details
  17. # Changing these values requires regeneration of the registration.
  18. appservice:
  19. # The address that the homeserver can use to connect to this appservice.
  20. address: {{ matrix_mautrix_twitter_appservice_address }}
  21. # When using https:// the TLS certificate and key files for the address.
  22. tls_cert: false
  23. tls_key: false
  24. # The hostname and port where this appservice should listen.
  25. hostname: 0.0.0.0
  26. port: 29327
  27. # The maximum body size of appservice API requests (from the homeserver) in mebibytes
  28. # Usually 1 is enough, but on high-traffic bridges you might need to increase this to avoid 413s
  29. max_body_size: 1
  30. # The full URI to the database. Only Postgres is currently supported.
  31. database: {{ matrix_mautrix_twitter_appservice_database|to_json }}
  32. # Additional arguments for asyncpg.create_pool()
  33. # https://magicstack.github.io/asyncpg/current/api/index.html#asyncpg.pool.create_pool
  34. database_opts:
  35. min_size: 5
  36. max_size: 10
  37. # Provisioning API part of the web server for automated portal creation and fetching information.
  38. # Used by things like mautrix-manager (https://github.com/tulir/mautrix-manager).
  39. provisioning:
  40. # Whether or not the provisioning API should be enabled.
  41. enabled: true
  42. # The prefix to use in the provisioning API endpoints.
  43. prefix: /_matrix/provision/v1
  44. # The shared secret to authorize users of the API.
  45. # Set to "generate" to generate and save a new token.
  46. shared_secret: generate
  47. # The unique ID of this appservice.
  48. id: twitter
  49. # Username of the appservice bot.
  50. bot_username: {{ matrix_mautrix_twitter_appservice_bot_username|to_json }}
  51. # Display name and avatar for bot. Set to "remove" to remove display name/avatar, leave empty
  52. # to leave display name/avatar as-is.
  53. bot_displayname: Twitter bridge bot
  54. bot_avatar: mxc://maunium.net/HVHcnusJkQcpVcsVGZRELLCn
  55. # Whether or not to receive ephemeral events via appservice transactions.
  56. # Requires MSC2409 support (i.e. Synapse 1.22+).
  57. # You should disable bridge -> sync_with_custom_puppets when this is enabled.
  58. ephemeral_events: false
  59. # Authentication tokens for AS <-> HS communication. Autogenerated; do not modify.
  60. as_token: "{{ matrix_mautrix_twitter_appservice_token }}"
  61. hs_token: "{{ matrix_mautrix_twitter_homeserver_token }}"
  62. # Prometheus telemetry config. Requires prometheus-client to be installed.
  63. metrics:
  64. enabled: {{ matrix_mautrix_twitter_metrics_enabled | to_json }}
  65. listen_port: 8000
  66. # Bridge config
  67. bridge:
  68. # Localpart template of MXIDs for Twitter users.
  69. # {userid} is replaced with the user ID of the Twitter user.
  70. username_template: "twitter_{userid}"
  71. # Displayname template for Twitter users.
  72. # {displayname} is replaced with the display name of the Twitter user.
  73. # {username} is replaced with the username of the Twitter user.
  74. displayname_template: "{displayname} (Twitter)"
  75. # Maximum length of displayname
  76. displayname_max_length: 100
  77. # Number of conversations to sync (and create portals for) on login.
  78. # Set 0 to disable automatic syncing.
  79. initial_conversation_sync: 10
  80. # Whether or not to use /sync to get read receipts and typing notifications
  81. # when double puppeting is enabled
  82. sync_with_custom_puppets: true
  83. # Whether or not to update the m.direct account data event when double puppeting is enabled.
  84. # Note that updating the m.direct event is not atomic (except with mautrix-asmux)
  85. # and is therefore prone to race conditions.
  86. sync_direct_chat_list: false
  87. # Allow using double puppeting from any server with a valid client .well-known file.
  88. double_puppet_allow_discovery: false
  89. # Servers to allow double puppeting from, even if double_puppet_allow_discovery is false.
  90. double_puppet_server_map: {}
  91. # Shared secret for https://github.com/devture/matrix-synapse-shared-secret-auth
  92. #
  93. # If set, custom puppets will be enabled automatically for local users
  94. # instead of users having to find an access token and run `login-matrix`
  95. # manually.
  96. # If using this for other servers than the bridge's server,
  97. # you must also set the URL in the double_puppet_server_map.
  98. login_shared_secret_map: {{ matrix_mautrix_twitter_bridge_login_shared_secret_map|to_json }}
  99. # Whether or not created rooms should have federation enabled.
  100. # If false, created portal rooms will never be federated.
  101. federate_rooms: {{ matrix_mautrix_twitter_federate_rooms|to_json }}
  102. # Settings for backfilling messages from Twitter.
  103. #
  104. # Missed message backfilling is currently based on receiving them from the Twitter polling API,
  105. # rather than manually asking for messages in each conversation. Due to this, there's no way to
  106. # set a limit for missed message backfilling.
  107. backfill:
  108. # Whether or not the Twitter users of logged in Matrix users should be
  109. # invited to private chats when backfilling history from Twitter. This is
  110. # usually needed to prevent rate limits and to allow timestamp massaging.
  111. invite_own_puppet: true
  112. # Maximum number of messages to backfill initially.
  113. # Set to 0 to disable backfilling when creating portal.
  114. initial_limit: 0
  115. # If using double puppeting, should notifications be disabled
  116. # while the initial backfill is in progress?
  117. disable_notifications: true
  118. # End-to-bridge encryption support options. You must install the e2be optional dependency for
  119. # this to work. See https://github.com/tulir/mautrix-telegram/wiki/End‐to‐bridge-encryption
  120. encryption:
  121. # Allow encryption, work in group chat rooms with e2ee enabled
  122. allow: {{ matrix_mautrix_twitter_bridge_encryption_allow|to_json }}
  123. # Default to encryption, force-enable encryption in all portals the bridge creates
  124. # This will cause the bridge bot to be in private chats for the encryption to work properly.
  125. default: {{ matrix_mautrix_twitter_bridge_encryption_default|to_json }}
  126. # Options for automatic key sharing.
  127. key_sharing:
  128. # Enable key sharing? If enabled, key requests for rooms where users are in will be fulfilled.
  129. # You must use a client that supports requesting keys from other users to use this feature.
  130. allow: {{ matrix_mautrix_twitter_bridge_encryption_key_sharing_allow|to_json }}
  131. # Require the requesting device to have a valid cross-signing signature?
  132. # This doesn't require that the bridge has verified the device, only that the user has verified it.
  133. # Not yet implemented.
  134. require_cross_signing: false
  135. # Require devices to be verified by the bridge?
  136. # Verification by the bridge is not yet implemented.
  137. require_verification: true
  138. # Whether or not to explicitly set the avatar and room name for private
  139. # chat portal rooms. This will be implicitly enabled if encryption.default is true.
  140. private_chat_portal_meta: false
  141. # Whether or not the bridge should send a read receipt from the bridge bot when a message has
  142. # been sent to Twitter.
  143. delivery_receipts: false
  144. # Whether or not delivery errors should be reported as messages in the Matrix room.
  145. delivery_error_reports: true
  146. # Whether or not non-fatal polling errors should send notices to the notice room.
  147. temporary_disconnect_notices: true
  148. # Number of seconds to sleep more than the previous error when a polling error occurs.
  149. # Growth is capped at 15 minutes.
  150. error_sleep: 5
  151. # Maximum number of polling errors before giving up. Set to -1 to retry forever.
  152. max_poll_errors: 12
  153. # Set this to true to tell the bridge to re-send m.bridge events to all rooms on the next run.
  154. # This field will automatically be changed back to false after it,
  155. # except if the config file is not writable.
  156. resend_bridge_info: false
  157. # The prefix for commands. Only required in non-management rooms.
  158. command_prefix: "{{ matrix_mautrix_twitter_command_prefix }}"
  159. # Permissions for using the bridge.
  160. # Permitted values:
  161. # user - Use the bridge with puppeting.
  162. # admin - Use and administrate the bridge.
  163. # Permitted keys:
  164. # * - All Matrix users
  165. # domain - All users on that homeserver
  166. # mxid - Specific user
  167. permissions: {{ matrix_mautrix_twitter_bridge_permissions|to_json }}
  168. # Python logging configuration.
  169. #
  170. # See section 16.7.2 of the Python documentation for more info:
  171. # https://docs.python.org/3.6/library/logging.config.html#configuration-dictionary-schema
  172. logging:
  173. version: 1
  174. formatters:
  175. colored:
  176. (): mautrix_twitter.util.ColorFormatter
  177. format: "[%(asctime)s] [%(levelname)s@%(name)s] %(message)s"
  178. normal:
  179. format: "[%(asctime)s] [%(levelname)s@%(name)s] %(message)s"
  180. handlers:
  181. console:
  182. class: logging.StreamHandler
  183. formatter: colored
  184. loggers:
  185. mau:
  186. level: {{ matrix_mautrix_twitter_logging_level|to_json }}
  187. aiohttp:
  188. level: {{ matrix_mautrix_twitter_logging_level|to_json }}
  189. root:
  190. level: {{ matrix_mautrix_twitter_logging_level|to_json }}
  191. handlers: [console]