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

182 строки
7.8 KiB

  1. # Mx Puppet Slack is a Matrix <-> Slack bridge
  2. # See: https://github.com/Sorunome/mx-puppet-slack
  3. matrix_mx_puppet_slack_enabled: true
  4. matrix_mx_puppet_slack_container_image_self_build: false
  5. matrix_mx_puppet_slack_docker_image: "sorunome/mx-puppet-slack:latest"
  6. matrix_mx_puppet_slack_docker_image_force_pull: "{{ matrix_mx_puppet_slack_docker_image.endswith(':latest') }}"
  7. matrix_mx_puppet_slack_base_path: "{{ matrix_base_data_path }}/mx-puppet-slack"
  8. matrix_mx_puppet_slack_config_path: "{{ matrix_mx_puppet_slack_base_path }}/config"
  9. matrix_mx_puppet_slack_data_path: "{{ matrix_mx_puppet_slack_base_path }}/data"
  10. matrix_mx_puppet_slack_docker_src_files_path: "{{ matrix_mx_puppet_slack_base_path }}/docker-src"
  11. matrix_mx_puppet_slack_appservice_port: "8432"
  12. matrix_mx_puppet_slack_homeserver_address: 'http://matrix-synapse:8008'
  13. matrix_mx_puppet_slack_homeserver_domain: '{{ matrix_domain }}'
  14. matrix_mx_puppet_slack_appservice_address: 'http://matrix-mx-puppet-slack:{{ matrix_mx_puppet_slack_appservice_port }}'
  15. matrix_mx_puppet_slack_client_id: ''
  16. matrix_mx_puppet_slack_client_secret: ''
  17. matrix_mx_puppet_slack_redirect_path: '/slack/oauth'
  18. matrix_mx_puppet_slack_redirect_uri: 'https://{{ matrix_server_fqn_matrix }}{{ matrix_mx_puppet_slack_redirect_path }}'
  19. # "@user:server.com" to allow specific user
  20. # "@.*:yourserver.com" to allow users on a specific homeserver
  21. # "@.*" to allow anyone
  22. matrix_mx_puppet_slack_provisioning_whitelist:
  23. - "@.*:{{ matrix_domain|regex_escape }}"
  24. # Leave empty to disable blacklist
  25. # "@user:server.com" disallow a specific user
  26. # "@.*:yourserver.com" disallow users on a specific homeserver
  27. matrix_mx_puppet_slack_provisioning_blacklist: []
  28. # A list of extra arguments to pass to the container
  29. matrix_mx_puppet_slack_container_extra_arguments: []
  30. # List of systemd services that matrix-puppet-slack.service depends on.
  31. matrix_mx_puppet_slack_systemd_required_services_list: ['docker.service']
  32. # List of systemd services that matrix-puppet-slack.service wants
  33. matrix_mx_puppet_slack_systemd_wanted_services_list: []
  34. matrix_mx_puppet_slack_appservice_token: ''
  35. matrix_mx_puppet_slack_homeserver_token: ''
  36. # Default configuration template which covers the generic use case.
  37. # You can customize it by controlling the various variables inside it.
  38. #
  39. # For a more advanced customization, you can extend the default (see `matrix_mx_puppet_slack_configuration_extension_yaml`)
  40. # or completely replace this variable with your own template.
  41. matrix_mx_puppet_slack_configuration_yaml: |
  42. #jinja2: lstrip_blocks: "True"
  43. bridge:
  44. # Port to host the bridge on
  45. # Used for communication between the homeserver and the bridge
  46. port: {{ matrix_mx_puppet_slack_appservice_port }}
  47. # The host connections to the bridge's webserver are allowed from
  48. bindAddress: 0.0.0.0
  49. # Public domain of the homeserver
  50. domain: {{ matrix_mx_puppet_slack_homeserver_domain }}
  51. # Reachable URL of the Matrix homeserver
  52. homeserverUrl: {{ matrix_mx_puppet_slack_homeserver_address }}
  53. # Slack OAuth settings. Create a slack app at https://api.slack.com/apps
  54. oauth:
  55. enabled: false
  56. # Slack app credentials.
  57. # N.B. This must be quoted so YAML wouldn't parse it as a float.
  58. clientId: "{{ matrix_mx_puppet_slack_client_id }}"
  59. clientSecret: {{ matrix_mx_puppet_slack_client_secret }}
  60. # Path where to listen for OAuth redirect callbacks.
  61. redirectPath: {{ matrix_mx_puppet_slack_redirect_path }}
  62. # Set up proxying from https://your.domain/redirect_path to http://bindAddress:port/redirect_path,
  63. # then set this field and the Slack app redirect URI field to the former.
  64. redirectUri: {{ matrix_mx_puppet_slack_redirect_uri }}
  65. presence:
  66. # Bridge Discord online/offline status
  67. enabled: true
  68. # How often to send status to the homeserver in milliseconds
  69. interval: 500
  70. provisioning:
  71. # Regex of Matrix IDs allowed to use the puppet bridge
  72. whitelist: {{ matrix_mx_puppet_slack_provisioning_whitelist|to_json }}
  73. # Allow a specific user
  74. #- "@user:server\\.com"
  75. # Allow users on a specific homeserver
  76. #- "@.*:yourserver\\.com"
  77. # Allow anyone
  78. #- ".*"
  79. # Regex of Matrix IDs forbidden from using the puppet bridge
  80. #blacklist:
  81. # Disallow a specific user
  82. #- "@user:server\\.com"
  83. # Disallow users on a specific homeserver
  84. #- "@.*:yourserver\\.com"
  85. blacklist: {{ matrix_mx_puppet_slack_provisioning_blacklist|to_json }}
  86. # Shared secret for the provisioning API for use by integration managers.
  87. # If this is not set, the provisioning API will not be enabled.
  88. #sharedSecret: random string
  89. # Path prefix for the provisioning API. /v1 will be appended to the prefix automatically.
  90. apiPrefix: /_matrix/provision
  91. database:
  92. # Use Postgres as a database backend
  93. # If set, will be used instead of SQLite3
  94. # Connection string to connect to the Postgres instance
  95. # with username "user", password "pass", host "localhost" and database name "dbname".
  96. # Modify each value as necessary
  97. #connString: "postgres://user:pass@localhost/dbname?sslmode=disable"
  98. # Use SQLite3 as a database backend
  99. # The name of the database file
  100. filename: /data/database.db
  101. logging:
  102. # Log level of console output
  103. # Allowed values starting with most verbose:
  104. # silly, debug, verbose, info, warn, error
  105. console: info
  106. # Date and time formatting
  107. lineDateFormat: MMM-D HH:mm:ss.SSS
  108. # Logging files
  109. # Log files are rotated daily by default
  110. files:
  111. # Log file path
  112. - file: "/data/bridge.log"
  113. # Log level for this file
  114. # Allowed values starting with most verbose:
  115. # silly, debug, verbose, info, warn, error
  116. level: info
  117. # Date and time formatting
  118. datePattern: YYYY-MM-DD
  119. # Maximum number of logs to keep.
  120. # This can be a number of files or number of days.
  121. # If using days, add 'd' as a suffix
  122. maxFiles: 14d
  123. # Maximum size of the file after which it will rotate. This can be a
  124. # number of bytes, or units of kb, mb, and gb. If using the units, add
  125. # 'k', 'm', or 'g' as the suffix
  126. maxSize: 50m
  127. matrix_mx_puppet_slack_configuration_extension_yaml: |
  128. # Your custom YAML configuration goes here.
  129. # This configuration extends the default starting configuration (`matrix_mx_puppet_slack_configuration_yaml`).
  130. #
  131. # You can override individual variables from the default configuration, or introduce new ones.
  132. #
  133. # If you need something more special, you can take full control by
  134. # completely redefining `matrix_mx_puppet_slack_configuration_yaml`.
  135. matrix_mx_puppet_slack_configuration_extension: "{{ matrix_mx_puppet_slack_configuration_extension_yaml|from_yaml if matrix_mx_puppet_slack_configuration_extension_yaml|from_yaml is mapping else {} }}"
  136. # Holds the final configuration (a combination of the default and its extension).
  137. # You most likely don't need to touch this variable. Instead, see `matrix_mx_puppet_slack_configuration_yaml`.
  138. matrix_mx_puppet_slack_configuration: "{{ matrix_mx_puppet_slack_configuration_yaml|from_yaml|combine(matrix_mx_puppet_slack_configuration_extension, recursive=True) }}"
  139. matrix_mx_puppet_slack_registration_yaml: |
  140. as_token: "{{ matrix_mx_puppet_slack_appservice_token }}"
  141. hs_token: "{{ matrix_mx_puppet_slack_homeserver_token }}"
  142. id: slack-puppet
  143. namespaces:
  144. users:
  145. - exclusive: true
  146. regex: '@_slackpuppet_.*:{{ matrix_mx_puppet_slack_homeserver_domain|regex_escape }}'
  147. rooms: []
  148. aliases:
  149. - exclusive: true
  150. regex: '#_slackpuppet_.*:{{ matrix_mx_puppet_slack_homeserver_domain|regex_escape }}'
  151. protocols: []
  152. rate_limited: false
  153. sender_localpart: _slackpuppet_bot
  154. url: {{ matrix_mx_puppet_slack_appservice_address }}
  155. matrix_mx_puppet_slack_registration: "{{ matrix_mx_puppet_slack_registration_yaml|from_yaml }}"