Matrix Docker Ansible eploy
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.
 
 

218 lignes
12 KiB

  1. ---
  2. # Project source code URL: https://github.com/turt2live/matrix-dimension
  3. matrix_dimension_enabled: false
  4. matrix_dimension_scheme: https
  5. # The hostname at which Dimension is served.
  6. matrix_dimension_hostname: ''
  7. # The path at which Dimension is exposed.
  8. # This value must either be `/` or not end with a slash (e.g. `/dimension`).
  9. matrix_dimension_path_prefix: /
  10. # You are required to specify an access token for Dimension to work.
  11. # For information on how to acquire an access token, visit https://t2bot.io/docs/access_tokens
  12. matrix_dimension_access_token: ""
  13. # Users in form: ['@user1:domain.com', '@user2:domain.com']
  14. matrix_dimension_admins: []
  15. # Whether to allow Dimension widgets serve websites with invalid or self signed SSL certificates
  16. matrix_dimension_widgets_allow_self_signed_ssl_certificates: false
  17. matrix_dimension_container_image_self_build: false
  18. matrix_dimension_container_image_self_build_repo: "https://github.com/turt2live/matrix-dimension.git"
  19. matrix_dimension_container_image_self_build_branch: master
  20. matrix_dimension_base_path: "{{ matrix_base_data_path }}/dimension"
  21. matrix_dimension_docker_src_files_path: "{{ matrix_base_data_path }}/docker-src/dimension"
  22. matrix_dimension_version: latest
  23. matrix_dimension_docker_image: "{{ matrix_dimension_docker_image_name_prefix }}turt2live/matrix-dimension:{{ matrix_dimension_version }}"
  24. matrix_dimension_docker_image_name_prefix: "{{ 'localhost/' if matrix_dimension_container_image_self_build else matrix_container_global_registry_prefix }}"
  25. matrix_dimension_docker_image_force_pull: "{{ matrix_dimension_docker_image.endswith(':latest') }}"
  26. # List of systemd services that matrix-dimension.service depends on.
  27. matrix_dimension_systemd_required_services_list: ['docker.service']
  28. # List of systemd services that matrix-dimension.service wants
  29. matrix_dimension_systemd_wanted_services_list: []
  30. # The user and group id correspond to the node user in the `turt2live/matrix-dimension` image.
  31. matrix_dimension_user_uid: '1000'
  32. matrix_dimension_user_gid: '1000'
  33. # The base container network. It will be auto-created by this role if it doesn't exist already.
  34. matrix_dimension_container_network: matrix-dimension
  35. # A list of additional container networks that the container would be connected to.
  36. # The role does not create these networks, so make sure they already exist.
  37. # Use this to expose this container to another reverse proxy, which runs in a different container network.
  38. matrix_dimension_container_additional_networks: []
  39. # Controls whether the matrix-dimension container exposes its HTTP port (tcp/8184 in the container).
  40. #
  41. # Takes an "<ip>:<port>" or "<port>" value (e.g. "127.0.0.1:8184"), or empty string to not expose.
  42. matrix_dimension_container_http_host_bind_port: ''
  43. # matrix_dimension_container_labels_traefik_enabled controls whether labels to assist a Traefik reverse-proxy will be attached to the container.
  44. # See `../templates/labels.j2` for details.
  45. #
  46. # To inject your own other container labels, see `matrix_dimension_container_labels_additional_labels`.
  47. matrix_dimension_container_labels_traefik_enabled: true
  48. matrix_dimension_container_labels_traefik_docker_network: "{{ matrix_dimension_container_network }}"
  49. matrix_dimension_container_labels_traefik_hostname: "{{ matrix_dimension_hostname }}"
  50. # The path prefix must either be `/` or not end with a slash (e.g. `/dimension`).
  51. matrix_dimension_container_labels_traefik_path_prefix: "{{ matrix_dimension_path_prefix }}"
  52. matrix_dimension_container_labels_traefik_rule: "Host(`{{ matrix_dimension_container_labels_traefik_hostname }}`){% if matrix_dimension_container_labels_traefik_path_prefix != '/' %} && PathPrefix(`{{ matrix_dimension_container_labels_traefik_path_prefix }}`){% endif %}"
  53. matrix_dimension_container_labels_traefik_priority: 0
  54. matrix_dimension_container_labels_traefik_entrypoints: web-secure
  55. matrix_dimension_container_labels_traefik_tls: "{{ matrix_dimension_container_labels_traefik_entrypoints != 'web' }}"
  56. matrix_dimension_container_labels_traefik_tls_certResolver: default # noqa var-naming
  57. # Controls which additional headers to attach to all HTTP responses.
  58. # To add your own headers, use `matrix_dimension_container_labels_traefik_additional_response_headers_custom`
  59. matrix_dimension_container_labels_traefik_additional_response_headers: "{{ matrix_dimension_container_labels_traefik_additional_response_headers_auto | combine(matrix_dimension_container_labels_traefik_additional_response_headers_custom) }}"
  60. matrix_dimension_container_labels_traefik_additional_response_headers_auto: |
  61. {{
  62. {}
  63. | combine ({'X-XSS-Protection': matrix_dimension_http_header_xss_protection} if matrix_dimension_http_header_xss_protection else {})
  64. | combine ({'X-Frame-Options': matrix_dimension_http_header_frame_options} if matrix_dimension_http_header_frame_options else {})
  65. | combine ({'X-Content-Type-Options': matrix_dimension_http_header_content_type_options} if matrix_dimension_http_header_content_type_options else {})
  66. | combine ({'Content-Security-Policy': matrix_dimension_http_header_content_security_policy} if matrix_dimension_http_header_content_security_policy else {})
  67. | combine ({'Permission-Policy': matrix_dimension_http_header_content_permission_policy} if matrix_dimension_http_header_content_permission_policy else {})
  68. | combine ({'Strict-Transport-Security': matrix_dimension_http_header_strict_transport_security} if matrix_dimension_http_header_strict_transport_security and matrix_dimension_container_labels_traefik_tls else {})
  69. }}
  70. matrix_dimension_container_labels_traefik_additional_response_headers_custom: {}
  71. # matrix_dimension_container_labels_additional_labels contains a multiline string with additional labels to add to the container label file.
  72. # See `../templates/labels.j2` for details.
  73. #
  74. # Example:
  75. # matrix_dimension_container_labels_additional_labels: |
  76. # my.label=1
  77. # another.label="here"
  78. matrix_dimension_container_labels_additional_labels: ''
  79. # A list of extra arguments to pass to the container
  80. matrix_dimension_container_extra_arguments: []
  81. # Public facing base URL of the Dimension service.
  82. # It should not end with a slash.
  83. matrix_dimension_base_url: "{{ matrix_dimension_scheme }}://{{ matrix_dimension_hostname }}{{ '' if matrix_dimension_path_prefix == '/' else matrix_dimension_path_prefix }}"
  84. matrix_dimension_integrations_ui_url: "{{ matrix_dimension_base_url }}/element"
  85. matrix_dimension_integrations_rest_url: "{{ matrix_dimension_base_url }}/api/v1/scalar"
  86. matrix_dimension_integrations_widgets_urls: ["{{ matrix_dimension_base_url }}/widgets"]
  87. matrix_dimension_integrations_jitsi_widget_url: "{{ matrix_dimension_base_url }}/widgets/jitsi"
  88. matrix_dimension_homeserver_clientServerUrl: '' # noqa var-naming
  89. matrix_dimension_homeserver_federationUrl: '' # noqa var-naming
  90. matrix_dimension_homeserver_mediaUrl: '' # noqa var-naming
  91. # Controls the dimension.publicUrl configuration option
  92. matrix_dimension_dimension_publicUrl: "{{ matrix_dimension_base_url }}" # noqa var-naming
  93. # Specifies the value of the `X-XSS-Protection` header
  94. # Stops pages from loading when they detect reflected cross-site scripting (XSS) attacks.
  95. #
  96. # Learn more about it is here:
  97. # - https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-XSS-Protection
  98. # - https://portswigger.net/web-security/cross-site-scripting/reflected
  99. matrix_dimension_http_header_xss_protection: "1; mode=block"
  100. # Specifies the value of the `X-Frame-Options` header which controls whether framing can happen.
  101. # See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Frame-Options
  102. matrix_dimension_http_header_frame_options: ''
  103. # Specifies the value of the `X-Content-Type-Options` header.
  104. # See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Content-Type-Options
  105. matrix_dimension_http_header_content_type_options: nosniff
  106. # Specifies the value of the `Content-Security-Policy` header.
  107. # See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy
  108. matrix_dimension_http_header_content_security_policy: ''
  109. # Specifies the value of the `Permission-Policy` header.
  110. # See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Permission-Policy
  111. matrix_dimension_http_header_content_permission_policy: "{{ 'interest-cohort=()' if matrix_dimension_floc_optout_enabled else '' }}"
  112. # Specifies the value of the `Strict-Transport-Security` header.
  113. # See: https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
  114. matrix_dimension_http_header_strict_transport_security: "max-age=31536000; includeSubDomains{{ '; preload' if matrix_dimension_hsts_preload_enabled else '' }}"
  115. # Controls whether to send a "Permissions-Policy interest-cohort=();" header along with all responses
  116. #
  117. # Learn more about what it is here:
  118. # - https://www.eff.org/deeplinks/2021/03/googles-floc-terrible-idea
  119. # - https://paramdeo.com/blog/opting-your-website-out-of-googles-floc-network
  120. # - https://amifloced.org/
  121. #
  122. # Of course, a better solution is to just stop using browsers (like Chrome), which participate in such tracking practices.
  123. # See: `matrix_dimension_content_permission_policy`
  124. matrix_dimension_floc_optout_enabled: true
  125. # Controls if HSTS preloading is enabled
  126. #
  127. # In its strongest and recommended form, the [HSTS policy](https://www.chromium.org/hsts) includes all subdomains, and
  128. # indicates a willingness to be "preloaded" into browsers:
  129. # `Strict-Transport-Security: max-age=31536000; includeSubDomains; preload`
  130. # For more information visit:
  131. # - https://en.wikipedia.org/wiki/HTTP_Strict_Transport_Security
  132. # - https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Strict-Transport-Security
  133. # - https://hstspreload.org/#opt-in
  134. # See: `matrix_dimension_http_header_strict_transport_security`
  135. matrix_dimension_hsts_preload_enabled: false
  136. # Database-related configuration fields.
  137. #
  138. # To use SQLite, stick to these defaults.
  139. #
  140. # To use Postgres:
  141. # - change the engine (`matrix_dimension_database_engine: 'postgres'`)
  142. # - adjust your database credentials via the `matrix_dimension_database_*` variables
  143. matrix_dimension_database_engine: 'sqlite'
  144. matrix_dimension_sqlite_database_path_local: "{{ matrix_dimension_base_path }}/dimension.db"
  145. matrix_dimension_sqlite_database_path_in_container: "dimension.db"
  146. matrix_dimension_database_username: 'matrix_dimension'
  147. matrix_dimension_database_password: 'some-password'
  148. matrix_dimension_database_hostname: ''
  149. matrix_dimension_database_port: 5432
  150. matrix_dimension_database_name: 'matrix_dimension'
  151. matrix_dimension_database_connection_string: 'postgres://{{ matrix_dimension_database_username }}:{{ matrix_dimension_database_password }}@{{ matrix_dimension_database_hostname }}:{{ matrix_dimension_database_port }}/{{ matrix_dimension_database_name }}'
  152. # Default Dimension configuration template which covers the generic use case.
  153. # You can customize it by controlling the various variables inside it.
  154. #
  155. # For a more advanced customization, you can extend the default (see `matrix_dimension_configuration_extension_yaml`)
  156. # or completely replace this variable with your own template.
  157. matrix_dimension_configuration_yaml: "{{ lookup('template', 'templates/config.yaml.j2') }}"
  158. matrix_dimension_configuration_extension_yaml: |
  159. # Your custom YAML configuration for Dimension goes here.
  160. # This configuration extends the default starting configuration (`matrix_dimension_configuration_yaml`).
  161. #
  162. # You can override individual variables from the default configuration, or introduce new ones.
  163. #
  164. # If you need something more special, you can take full control by
  165. # completely redefining `matrix_dimension_configuration_yaml`.
  166. #
  167. # Example configuration extension follows:
  168. # telegram:
  169. # botToken: "YourTokenHere"
  170. #
  171. matrix_dimension_configuration_extension: "{{ matrix_dimension_configuration_extension_yaml | from_yaml if matrix_dimension_configuration_extension_yaml | from_yaml is mapping else {} }}"
  172. # Holds the final Dimension configuration (a combination of the default and its extension).
  173. # You most likely don't need to touch this variable. Instead, see `matrix_dimension_configuration_yaml`.
  174. matrix_dimension_configuration: "{{ matrix_dimension_configuration_yaml | from_yaml | combine(matrix_dimension_configuration_extension, recursive=True) }}"