Rename matrix_mx_puppet_groupme_* variables to matrix_bridge_mx_puppet_groupme_*

Part of adopting a uniform naming policy for bridge variables,
where the variable prefix matches the role directory name.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Slavi Pantaleev
2026-07-16 14:58:10 +03:00
parent 97077e2f13
commit 7380cbdc3c
9 changed files with 183 additions and 183 deletions
@@ -18,7 +18,7 @@ See the project's [documentation](https://gitlab.com/xangelix-pub/matrix/mx-pupp
To enable the [GroupMe](https://groupme.com/) bridge, add the following configuration to your `inventory/host_vars/matrix.example.com/vars.yml` file: To enable the [GroupMe](https://groupme.com/) bridge, add the following configuration to your `inventory/host_vars/matrix.example.com/vars.yml` file:
```yaml ```yaml
matrix_mx_puppet_groupme_enabled: true matrix_bridge_mx_puppet_groupme_enabled: true
``` ```
## Installing ## Installing
+25 -25
View File
@@ -140,7 +140,7 @@ matrix_homeserver_container_extra_arguments_auto: |
+ +
(['--mount type=bind,src=' + matrix_bridge_mautrix_wsproxy_config_path + '/imessage-registration.yaml,dst=/matrix-mautrix-imessage-registration.yaml,ro'] if matrix_bridge_mautrix_wsproxy_enabled else []) (['--mount type=bind,src=' + matrix_bridge_mautrix_wsproxy_config_path + '/imessage-registration.yaml,dst=/matrix-mautrix-imessage-registration.yaml,ro'] if matrix_bridge_mautrix_wsproxy_enabled else [])
+ +
(['--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 []) (['--mount type=bind,src=' + matrix_bridge_mx_puppet_groupme_config_path + '/registration.yaml,dst=/matrix-mx-puppet-groupme-registration.yaml,ro'] if matrix_bridge_mx_puppet_groupme_enabled else [])
+ +
(['--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 []) (['--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 [])
+ +
@@ -199,7 +199,7 @@ matrix_homeserver_app_service_config_files_auto: |
+ +
(['/matrix-mautrix-imessage-registration.yaml'] if matrix_bridge_mautrix_wsproxy_enabled else []) (['/matrix-mautrix-imessage-registration.yaml'] if matrix_bridge_mautrix_wsproxy_enabled else [])
+ +
(['/matrix-mx-puppet-groupme-registration.yaml'] if matrix_mx_puppet_groupme_enabled else []) (['/matrix-mx-puppet-groupme-registration.yaml'] if matrix_bridge_mx_puppet_groupme_enabled else [])
+ +
(['/matrix-mx-puppet-steam-registration.yaml'] if matrix_mx_puppet_steam_enabled else []) (['/matrix-mx-puppet-steam-registration.yaml'] if matrix_mx_puppet_steam_enabled else [])
+ +
@@ -520,9 +520,9 @@ devture_systemd_service_manager_services_list_auto: |
([{ ([{
'name': 'matrix-mx-puppet-groupme.service', 'name': 'matrix-mx-puppet-groupme.service',
'priority': 2000, 'priority': 2000,
'restart_necessary': (matrix_mx_puppet_groupme_restart_necessary | bool), 'restart_necessary': (matrix_bridge_mx_puppet_groupme_restart_necessary | bool),
'groups': ['matrix', 'bridges', 'mx-puppet-groupme'], 'groups': ['matrix', 'bridges', 'mx-puppet-groupme'],
}] if matrix_mx_puppet_groupme_enabled else []) }] if matrix_bridge_mx_puppet_groupme_enabled else [])
+ +
([{ ([{
'name': 'matrix-mx-puppet-steam.service', 'name': 'matrix-mx-puppet-steam.service',
@@ -2724,43 +2724,43 @@ matrix_mx_puppet_steam_database_password: "{{ (matrix_homeserver_generic_secret_
###################################################################### ######################################################################
# We don't enable bridges by default. # We don't enable bridges by default.
matrix_mx_puppet_groupme_enabled: false matrix_bridge_mx_puppet_groupme_enabled: false
matrix_mx_puppet_groupme_systemd_required_services_list_auto: | matrix_bridge_mx_puppet_groupme_systemd_required_services_list_auto: |
{{ {{
matrix_addons_homeserver_systemd_services_list matrix_addons_homeserver_systemd_services_list
+ +
([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_mx_puppet_groupme_database_hostname == postgres_connection_hostname) else []) ([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_bridge_mx_puppet_groupme_database_hostname == postgres_connection_hostname) else [])
}} }}
matrix_mx_puppet_groupme_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_mx_puppet_groupme_container_image_registry_prefix_upstream_default }}" matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream_default }}"
matrix_mx_puppet_groupme_container_image_self_build: "{{ matrix_architecture != 'amd64' }}" matrix_bridge_mx_puppet_groupme_container_image_self_build: "{{ matrix_architecture != 'amd64' }}"
matrix_mx_puppet_groupme_container_network: "{{ matrix_addons_container_network }}" matrix_bridge_mx_puppet_groupme_container_network: "{{ matrix_addons_container_network }}"
matrix_mx_puppet_groupme_container_additional_networks_auto: |- matrix_bridge_mx_puppet_groupme_container_additional_networks_auto: |-
{{ {{
( (
([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network]) ([] if matrix_addons_homeserver_container_network == '' else [matrix_addons_homeserver_container_network])
+ +
([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 []) ([postgres_container_network] if (postgres_enabled and matrix_bridge_mx_puppet_groupme_database_hostname == postgres_connection_hostname and matrix_bridge_mx_puppet_groupme_container_network != postgres_container_network) else [])
) | unique ) | unique
}} }}
matrix_mx_puppet_groupme_appservice_token: "{{ (matrix_homeserver_generic_secret_key + ':mxgro.as.tok') | hash('sha512') | to_uuid }}" matrix_bridge_mx_puppet_groupme_appservice_token: "{{ (matrix_homeserver_generic_secret_key + ':mxgro.as.tok') | hash('sha512') | to_uuid }}"
matrix_mx_puppet_groupme_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}" matrix_bridge_mx_puppet_groupme_homeserver_address: "{{ matrix_addons_homeserver_client_api_url }}"
matrix_mx_puppet_groupme_homeserver_token: "{{ (matrix_homeserver_generic_secret_key + ':mxgro.hs.tok') | hash('sha512') | to_uuid }}" matrix_bridge_mx_puppet_groupme_homeserver_token: "{{ (matrix_homeserver_generic_secret_key + ':mxgro.hs.tok') | hash('sha512') | to_uuid }}"
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 '' }}" matrix_bridge_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 '' }}"
matrix_mx_puppet_groupme_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}" matrix_bridge_mx_puppet_groupme_presence_enabled: "{{ matrix_homeserver_implementation != 'synapse' or matrix_synapse_presence_enabled }}"
# Postgres is the default, except if not using internal Postgres server # Postgres is the default, except if not using internal Postgres server
matrix_mx_puppet_groupme_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}" matrix_bridge_mx_puppet_groupme_database_engine: "{{ 'postgres' if postgres_enabled else 'sqlite' }}"
matrix_mx_puppet_groupme_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}" matrix_bridge_mx_puppet_groupme_database_hostname: "{{ postgres_connection_hostname if postgres_enabled else '' }}"
matrix_mx_puppet_groupme_database_password: "{{ (matrix_homeserver_generic_secret_key + ':mxpup.groupme.db') | hash('sha512') | to_uuid }}" matrix_bridge_mx_puppet_groupme_database_password: "{{ (matrix_homeserver_generic_secret_key + ':mxpup.groupme.db') | hash('sha512') | to_uuid }}"
###################################################################### ######################################################################
# #
@@ -4261,10 +4261,10 @@ postgres_managed_databases_auto: |
}] 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 []) }] 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 [])
+ +
([{ ([{
'name': matrix_mx_puppet_groupme_database_name, 'name': matrix_bridge_mx_puppet_groupme_database_name,
'username': matrix_mx_puppet_groupme_database_username, 'username': matrix_bridge_mx_puppet_groupme_database_username,
'password': matrix_mx_puppet_groupme_database_password, 'password': matrix_bridge_mx_puppet_groupme_database_password,
}] 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 []) }] if (matrix_bridge_mx_puppet_groupme_enabled and matrix_bridge_mx_puppet_groupme_database_engine == 'postgres' and matrix_bridge_mx_puppet_groupme_database_hostname == postgres_connection_hostname) else [])
+ +
([{ ([{
'name': matrix_steam_bridge_database_name, 'name': matrix_steam_bridge_database_name,
@@ -5192,7 +5192,7 @@ matrix_ketesa_config_asManagedUsers_auto: |
+ +
([ ([
'^@_groupmepuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$', '^@_groupmepuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
] if matrix_mx_puppet_groupme_enabled else []) ] if matrix_bridge_mx_puppet_groupme_enabled else [])
+ +
([ ([
'^@_steampuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$', '^@_steampuppet_[a-zA-Z0-9]+:'+(matrix_domain | regex_escape)+'$',
@@ -13,130 +13,130 @@
# Mx Puppet GroupMe is a Matrix <-> GroupMe bridge # Mx Puppet GroupMe is a Matrix <-> GroupMe bridge
# Project source code URL: https://gitlab.com/xangelix-pub/matrix/mx-puppet-groupme # Project source code URL: https://gitlab.com/xangelix-pub/matrix/mx-puppet-groupme
matrix_mx_puppet_groupme_enabled: true matrix_bridge_mx_puppet_groupme_enabled: true
matrix_mx_puppet_groupme_container_image_self_build: false matrix_bridge_mx_puppet_groupme_container_image_self_build: false
matrix_mx_puppet_groupme_container_image_self_build_repo: "https://gitlab.com/xangelix-pub/matrix/mx-puppet-groupme" matrix_bridge_mx_puppet_groupme_container_image_self_build_repo: "https://gitlab.com/xangelix-pub/matrix/mx-puppet-groupme"
matrix_mx_puppet_groupme_container_image_self_build_repo_version: "{{ 'main' if matrix_mx_puppet_groupme_version == 'latest' else matrix_mx_puppet_groupme_version }}" matrix_bridge_mx_puppet_groupme_container_image_self_build_repo_version: "{{ 'main' if matrix_bridge_mx_puppet_groupme_version == 'latest' else matrix_bridge_mx_puppet_groupme_version }}"
# Controls whether the mx-puppet-groupme container exposes its HTTP port (tcp/8437 in the container). # Controls whether the mx-puppet-groupme container exposes its HTTP port (tcp/8437 in the container).
# #
# Takes an "<ip>:<port>" or "<port>" value (e.g. "127.0.0.1:8437"), or empty string to not expose. # Takes an "<ip>:<port>" or "<port>" value (e.g. "127.0.0.1:8437"), or empty string to not expose.
matrix_mx_puppet_groupme_container_http_host_bind_port: '' matrix_bridge_mx_puppet_groupme_container_http_host_bind_port: ''
matrix_mx_puppet_groupme_version: 533cccc8 matrix_bridge_mx_puppet_groupme_version: 533cccc8
matrix_mx_puppet_groupme_container_image: "{{ matrix_mx_puppet_groupme_container_image_registry_prefix }}xangelix-pub/matrix/mx-puppet-groupme:{{ matrix_mx_puppet_groupme_version }}" matrix_bridge_mx_puppet_groupme_container_image: "{{ matrix_bridge_mx_puppet_groupme_container_image_registry_prefix }}xangelix-pub/matrix/mx-puppet-groupme:{{ matrix_bridge_mx_puppet_groupme_version }}"
matrix_mx_puppet_groupme_container_image_registry_prefix: "{{ 'localhost/' if matrix_mx_puppet_groupme_container_image_self_build else matrix_mx_puppet_groupme_container_image_registry_prefix_upstream }}" matrix_bridge_mx_puppet_groupme_container_image_registry_prefix: "{{ 'localhost/' if matrix_bridge_mx_puppet_groupme_container_image_self_build else matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream }}"
matrix_mx_puppet_groupme_container_image_registry_prefix_upstream: "{{ matrix_mx_puppet_groupme_container_image_registry_prefix_upstream_default }}" matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream: "{{ matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream_default }}"
matrix_mx_puppet_groupme_container_image_registry_prefix_upstream_default: "registry.gitlab.com/" matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream_default: "registry.gitlab.com/"
matrix_mx_puppet_groupme_base_path: "{{ matrix_base_data_path }}/mx-puppet-groupme" matrix_bridge_mx_puppet_groupme_base_path: "{{ matrix_base_data_path }}/mx-puppet-groupme"
matrix_mx_puppet_groupme_config_path: "{{ matrix_mx_puppet_groupme_base_path }}/config" matrix_bridge_mx_puppet_groupme_config_path: "{{ matrix_bridge_mx_puppet_groupme_base_path }}/config"
matrix_mx_puppet_groupme_data_path: "{{ matrix_mx_puppet_groupme_base_path }}/data" matrix_bridge_mx_puppet_groupme_data_path: "{{ matrix_bridge_mx_puppet_groupme_base_path }}/data"
matrix_mx_puppet_groupme_container_src_files_path: "{{ matrix_mx_puppet_groupme_base_path }}/docker-src" matrix_bridge_mx_puppet_groupme_container_src_files_path: "{{ matrix_bridge_mx_puppet_groupme_base_path }}/docker-src"
matrix_mx_puppet_groupme_appservice_port: "8437" matrix_bridge_mx_puppet_groupme_appservice_port: "8437"
matrix_mx_puppet_groupme_homeserver_address: "" matrix_bridge_mx_puppet_groupme_homeserver_address: ""
matrix_mx_puppet_groupme_homeserver_domain: '{{ matrix_domain }}' matrix_bridge_mx_puppet_groupme_homeserver_domain: '{{ matrix_domain }}'
matrix_mx_puppet_groupme_appservice_address: 'http://matrix-mx-puppet-groupme:{{ matrix_mx_puppet_groupme_appservice_port }}' matrix_bridge_mx_puppet_groupme_appservice_address: 'http://matrix-mx-puppet-groupme:{{ matrix_bridge_mx_puppet_groupme_appservice_port }}'
# "@alice:example.com" to allow a specific user # "@alice:example.com" to allow a specific user
# "@.*:example.com" to allow users on a specific homeserver # "@.*:example.com" to allow users on a specific homeserver
# "@.*" to allow anyone # "@.*" to allow anyone
matrix_mx_puppet_groupme_provisioning_whitelist: matrix_bridge_mx_puppet_groupme_provisioning_whitelist:
- "@.*:{{ matrix_domain | regex_escape }}" - "@.*:{{ matrix_domain | regex_escape }}"
# Leave empty to disable blacklist # Leave empty to disable blacklist
# "@bob:example.com" to disallow a specific user # "@bob:example.com" to disallow a specific user
# "@.*:example.com" to disallow users on a specific homeserver # "@.*:example.com" to disallow users on a specific homeserver
matrix_mx_puppet_groupme_provisioning_blacklist: [] matrix_bridge_mx_puppet_groupme_provisioning_blacklist: []
matrix_mx_puppet_groupme_container_network: "" matrix_bridge_mx_puppet_groupme_container_network: ""
matrix_mx_puppet_groupme_container_additional_networks: "{{ matrix_mx_puppet_groupme_container_additional_networks_auto + matrix_mx_puppet_groupme_container_additional_networks_custom }}" matrix_bridge_mx_puppet_groupme_container_additional_networks: "{{ matrix_bridge_mx_puppet_groupme_container_additional_networks_auto + matrix_bridge_mx_puppet_groupme_container_additional_networks_custom }}"
matrix_mx_puppet_groupme_container_additional_networks_auto: [] matrix_bridge_mx_puppet_groupme_container_additional_networks_auto: []
matrix_mx_puppet_groupme_container_additional_networks_custom: [] matrix_bridge_mx_puppet_groupme_container_additional_networks_custom: []
# A list of extra arguments to pass to the container # A list of extra arguments to pass to the container
matrix_mx_puppet_groupme_container_extra_arguments: [] matrix_bridge_mx_puppet_groupme_container_extra_arguments: []
# List of systemd services that matrix-puppet-groupme.service depends on. # List of systemd services that matrix-puppet-groupme.service depends on.
matrix_mx_puppet_groupme_systemd_required_services_list: "{{ matrix_mx_puppet_groupme_systemd_required_services_list_default + matrix_mx_puppet_groupme_systemd_required_services_list_auto + matrix_mx_puppet_groupme_systemd_required_services_list_custom }}" matrix_bridge_mx_puppet_groupme_systemd_required_services_list: "{{ matrix_bridge_mx_puppet_groupme_systemd_required_services_list_default + matrix_bridge_mx_puppet_groupme_systemd_required_services_list_auto + matrix_bridge_mx_puppet_groupme_systemd_required_services_list_custom }}"
matrix_mx_puppet_groupme_systemd_required_services_list_default: "{{ [devture_systemd_docker_base_docker_service_name] if devture_systemd_docker_base_docker_service_name else [] }}" matrix_bridge_mx_puppet_groupme_systemd_required_services_list_default: "{{ [devture_systemd_docker_base_docker_service_name] if devture_systemd_docker_base_docker_service_name else [] }}"
matrix_mx_puppet_groupme_systemd_required_services_list_auto: [] matrix_bridge_mx_puppet_groupme_systemd_required_services_list_auto: []
matrix_mx_puppet_groupme_systemd_required_services_list_custom: [] matrix_bridge_mx_puppet_groupme_systemd_required_services_list_custom: []
# List of systemd services that matrix-puppet-groupme.service wants # List of systemd services that matrix-puppet-groupme.service wants
matrix_mx_puppet_groupme_systemd_wanted_services_list: [] matrix_bridge_mx_puppet_groupme_systemd_wanted_services_list: []
matrix_mx_puppet_groupme_appservice_token: '' matrix_bridge_mx_puppet_groupme_appservice_token: ''
matrix_mx_puppet_groupme_homeserver_token: '' matrix_bridge_mx_puppet_groupme_homeserver_token: ''
# Can be set to enable automatic double-puppeting via Shared Secret Auth (https://github.com/devture/matrix-synapse-shared-secret-auth). # Can be set to enable automatic double-puppeting via Shared Secret Auth (https://github.com/devture/matrix-synapse-shared-secret-auth).
matrix_mx_puppet_groupme_login_shared_secret: '' matrix_bridge_mx_puppet_groupme_login_shared_secret: ''
matrix_mx_puppet_groupme_presence_enabled: true matrix_bridge_mx_puppet_groupme_presence_enabled: true
matrix_mx_puppet_groupme_presence_interval: 5000 matrix_bridge_mx_puppet_groupme_presence_interval: 5000
matrix_mx_puppet_groupme_database_engine: sqlite matrix_bridge_mx_puppet_groupme_database_engine: sqlite
matrix_mx_puppet_groupme_sqlite_database_path_local: "{{ matrix_mx_puppet_groupme_data_path }}/database.db" matrix_bridge_mx_puppet_groupme_sqlite_database_path_local: "{{ matrix_bridge_mx_puppet_groupme_data_path }}/database.db"
matrix_mx_puppet_groupme_sqlite_database_path_in_container: "/data/database.db" matrix_bridge_mx_puppet_groupme_sqlite_database_path_in_container: "/data/database.db"
matrix_mx_puppet_groupme_database_username: matrix_mx_puppet_groupme matrix_bridge_mx_puppet_groupme_database_username: matrix_mx_puppet_groupme
matrix_mx_puppet_groupme_database_password: ~ matrix_bridge_mx_puppet_groupme_database_password: ~
matrix_mx_puppet_groupme_database_hostname: '' matrix_bridge_mx_puppet_groupme_database_hostname: ''
matrix_mx_puppet_groupme_database_port: 5432 matrix_bridge_mx_puppet_groupme_database_port: 5432
matrix_mx_puppet_groupme_database_name: matrix_mx_puppet_groupme matrix_bridge_mx_puppet_groupme_database_name: matrix_mx_puppet_groupme
matrix_mx_puppet_groupme_database_sslmode: disable matrix_bridge_mx_puppet_groupme_database_sslmode: disable
matrix_mx_puppet_groupme_database_connection_string: 'postgresql://{{ matrix_mx_puppet_groupme_database_username }}:{{ matrix_mx_puppet_groupme_database_password }}@{{ matrix_mx_puppet_groupme_database_hostname }}:{{ matrix_mx_puppet_groupme_database_port }}/{{ matrix_mx_puppet_groupme_database_name }}?sslmode={{ matrix_mx_puppet_groupme_database_sslmode }}' matrix_bridge_mx_puppet_groupme_database_connection_string: 'postgresql://{{ matrix_bridge_mx_puppet_groupme_database_username }}:{{ matrix_bridge_mx_puppet_groupme_database_password }}@{{ matrix_bridge_mx_puppet_groupme_database_hostname }}:{{ matrix_bridge_mx_puppet_groupme_database_port }}/{{ matrix_bridge_mx_puppet_groupme_database_name }}?sslmode={{ matrix_bridge_mx_puppet_groupme_database_sslmode }}'
# Default configuration template which covers the generic use case. # Default configuration template which covers the generic use case.
# You can customize it by controlling the various variables inside it. # You can customize it by controlling the various variables inside it.
# #
# For a more advanced customization, you can extend the default (see `matrix_mx_puppet_groupme_configuration_extension_yaml`) # For a more advanced customization, you can extend the default (see `matrix_bridge_mx_puppet_groupme_configuration_extension_yaml`)
# or completely replace this variable with your own template. # or completely replace this variable with your own template.
matrix_mx_puppet_groupme_configuration_yaml: "{{ lookup('template', 'templates/config.yaml.j2') }}" matrix_bridge_mx_puppet_groupme_configuration_yaml: "{{ lookup('template', 'templates/config.yaml.j2') }}"
matrix_mx_puppet_groupme_configuration_extension_yaml: | matrix_bridge_mx_puppet_groupme_configuration_extension_yaml: |
# Your custom YAML configuration goes here. # Your custom YAML configuration goes here.
# This configuration extends the default starting configuration (`matrix_mx_puppet_groupme_configuration_yaml`). # This configuration extends the default starting configuration (`matrix_bridge_mx_puppet_groupme_configuration_yaml`).
# #
# You can override individual variables from the default configuration, or introduce new ones. # You can override individual variables from the default configuration, or introduce new ones.
# #
# If you need something more special, you can take full control by # If you need something more special, you can take full control by
# completely redefining `matrix_mx_puppet_groupme_configuration_yaml`. # completely redefining `matrix_bridge_mx_puppet_groupme_configuration_yaml`.
matrix_mx_puppet_groupme_configuration_extension: "{{ matrix_mx_puppet_groupme_configuration_extension_yaml | from_yaml if matrix_mx_puppet_groupme_configuration_extension_yaml | from_yaml is mapping else {} }}" matrix_bridge_mx_puppet_groupme_configuration_extension: "{{ matrix_bridge_mx_puppet_groupme_configuration_extension_yaml | from_yaml if matrix_bridge_mx_puppet_groupme_configuration_extension_yaml | from_yaml is mapping else {} }}"
# Holds the final configuration (a combination of the default and its extension). # Holds the final configuration (a combination of the default and its extension).
# You most likely don't need to touch this variable. Instead, see `matrix_mx_puppet_groupme_configuration_yaml`. # You most likely don't need to touch this variable. Instead, see `matrix_bridge_mx_puppet_groupme_configuration_yaml`.
matrix_mx_puppet_groupme_configuration: "{{ matrix_mx_puppet_groupme_configuration_yaml | from_yaml | combine(matrix_mx_puppet_groupme_configuration_extension, recursive=True) }}" matrix_bridge_mx_puppet_groupme_configuration: "{{ matrix_bridge_mx_puppet_groupme_configuration_yaml | from_yaml | combine(matrix_bridge_mx_puppet_groupme_configuration_extension, recursive=True) }}"
matrix_mx_puppet_groupme_registration_yaml: | matrix_bridge_mx_puppet_groupme_registration_yaml: |
as_token: "{{ matrix_mx_puppet_groupme_appservice_token }}" as_token: "{{ matrix_bridge_mx_puppet_groupme_appservice_token }}"
hs_token: "{{ matrix_mx_puppet_groupme_homeserver_token }}" hs_token: "{{ matrix_bridge_mx_puppet_groupme_homeserver_token }}"
id: groupme-puppet id: groupme-puppet
namespaces: namespaces:
users: users:
- exclusive: true - exclusive: true
regex: '@_groupmepuppet_.*:{{ matrix_mx_puppet_groupme_homeserver_domain | regex_escape }}' regex: '@_groupmepuppet_.*:{{ matrix_bridge_mx_puppet_groupme_homeserver_domain | regex_escape }}'
rooms: [] rooms: []
aliases: aliases:
- exclusive: true - exclusive: true
regex: '#_groupmepuppet_.*:{{ matrix_mx_puppet_groupme_homeserver_domain | regex_escape }}' regex: '#_groupmepuppet_.*:{{ matrix_bridge_mx_puppet_groupme_homeserver_domain | regex_escape }}'
protocols: [] protocols: []
rate_limited: false rate_limited: false
sender_localpart: _groupmepuppet_bot sender_localpart: _groupmepuppet_bot
url: {{ matrix_mx_puppet_groupme_appservice_address }} url: {{ matrix_bridge_mx_puppet_groupme_appservice_address }}
de.sorunome.msc2409.push_ephemeral: true de.sorunome.msc2409.push_ephemeral: true
receive_ephemeral: true receive_ephemeral: true
matrix_mx_puppet_groupme_registration: "{{ matrix_mx_puppet_groupme_registration_yaml | from_yaml }}" matrix_bridge_mx_puppet_groupme_registration: "{{ matrix_bridge_mx_puppet_groupme_registration_yaml | from_yaml }}"
# matrix_mx_puppet_groupme_restart_necessary controls whether the service # matrix_bridge_mx_puppet_groupme_restart_necessary controls whether the service
# will be restarted (when true) or merely started (when false) by the # will be restarted (when true) or merely started (when false) by the
# systemd service manager role (when conditional restart is enabled). # systemd service manager role (when conditional restart is enabled).
# #
@@ -144,4 +144,4 @@ matrix_mx_puppet_groupme_registration: "{{ matrix_mx_puppet_groupme_registration
# any configuration files, the systemd service file, or the container image changed. # any configuration files, the systemd service file, or the container image changed.
# The default of `false` means "no restart needed" — appropriate when the role's # The default of `false` means "no restart needed" — appropriate when the role's
# installation tasks haven't run (e.g., due to --tags skipping them). # installation tasks haven't run (e.g., due to --tags skipping them).
matrix_mx_puppet_groupme_restart_necessary: false matrix_bridge_mx_puppet_groupme_restart_necessary: false
@@ -12,15 +12,15 @@
- install-all - install-all
- install-mx-puppet-groupme - install-mx-puppet-groupme
block: block:
- when: matrix_mx_puppet_groupme_enabled | bool - when: matrix_bridge_mx_puppet_groupme_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml" ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml"
- when: matrix_mx_puppet_groupme_enabled | bool - when: matrix_bridge_mx_puppet_groupme_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_install.yml" ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_install.yml"
- tags: - tags:
- setup-all - setup-all
- setup-mx-puppet-groupme - setup-mx-puppet-groupme
block: block:
- when: not matrix_mx_puppet_groupme_enabled | bool - when: not matrix_bridge_mx_puppet_groupme_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_uninstall.yml" ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_uninstall.yml"
@@ -18,16 +18,16 @@
owner: "{{ matrix_user_name }}" owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}" group: "{{ matrix_group_name }}"
with_items: with_items:
- {path: "{{ matrix_mx_puppet_groupme_base_path }}", when: true} - {path: "{{ matrix_bridge_mx_puppet_groupme_base_path }}", when: true}
- {path: "{{ matrix_mx_puppet_groupme_config_path }}", when: true} - {path: "{{ matrix_bridge_mx_puppet_groupme_config_path }}", when: true}
- {path: "{{ matrix_mx_puppet_groupme_data_path }}", when: true} - {path: "{{ matrix_bridge_mx_puppet_groupme_data_path }}", when: true}
- {path: "{{ matrix_mx_puppet_groupme_container_src_files_path }}", when: "{{ matrix_mx_puppet_groupme_container_image_self_build }}"} - {path: "{{ matrix_bridge_mx_puppet_groupme_container_src_files_path }}", when: "{{ matrix_bridge_mx_puppet_groupme_container_image_self_build }}"}
when: matrix_mx_puppet_groupme_enabled | bool and item.when | bool when: matrix_bridge_mx_puppet_groupme_enabled | bool and item.when | bool
- name: Check if an old database file already exists - name: Check if an old database file already exists
ansible.builtin.stat: ansible.builtin.stat:
path: "{{ matrix_mx_puppet_groupme_base_path }}/database.db" path: "{{ matrix_bridge_mx_puppet_groupme_base_path }}/database.db"
register: matrix_mx_puppet_groupme_stat_database register: matrix_bridge_mx_puppet_groupme_stat_database
- name: (Data relocation) Ensure matrix-mx-puppet-groupme.service is stopped - name: (Data relocation) Ensure matrix-mx-puppet-groupme.service is stopped
ansible.builtin.service: ansible.builtin.service:
@@ -36,96 +36,96 @@
enabled: false enabled: false
daemon_reload: true daemon_reload: true
failed_when: false failed_when: false
when: "matrix_mx_puppet_groupme_stat_database.stat.exists" when: "matrix_bridge_mx_puppet_groupme_stat_database.stat.exists"
- name: (Data relocation) Move mx-puppet-groupme database file to ./data directory - name: (Data relocation) Move mx-puppet-groupme database file to ./data directory
ansible.builtin.command: ansible.builtin.command:
cmd: "mv {{ matrix_mx_puppet_groupme_base_path }}/database.db {{ matrix_mx_puppet_groupme_data_path }}/database.db" cmd: "mv {{ matrix_bridge_mx_puppet_groupme_base_path }}/database.db {{ matrix_bridge_mx_puppet_groupme_data_path }}/database.db"
creates: "{{ matrix_mx_puppet_groupme_data_path }}/database.db" creates: "{{ matrix_bridge_mx_puppet_groupme_data_path }}/database.db"
removes: "{{ matrix_mx_puppet_groupme_base_path }}/database.db" removes: "{{ matrix_bridge_mx_puppet_groupme_base_path }}/database.db"
when: "matrix_mx_puppet_groupme_stat_database.stat.exists" when: "matrix_bridge_mx_puppet_groupme_stat_database.stat.exists"
- ansible.builtin.set_fact: - ansible.builtin.set_fact:
matrix_mx_puppet_groupme_migration_requires_restart: false matrix_bridge_mx_puppet_groupme_migration_requires_restart: false
- when: "matrix_mx_puppet_groupme_database_engine == 'postgres'" - when: "matrix_bridge_mx_puppet_groupme_database_engine == 'postgres'"
block: block:
- name: Check if an SQLite database already exists - name: Check if an SQLite database already exists
ansible.builtin.stat: ansible.builtin.stat:
path: "{{ matrix_mx_puppet_groupme_sqlite_database_path_local }}" path: "{{ matrix_bridge_mx_puppet_groupme_sqlite_database_path_local }}"
register: matrix_mx_puppet_groupme_sqlite_database_path_local_stat_result register: matrix_bridge_mx_puppet_groupme_sqlite_database_path_local_stat_result
- when: "matrix_mx_puppet_groupme_sqlite_database_path_local_stat_result.stat.exists | bool" - when: "matrix_bridge_mx_puppet_groupme_sqlite_database_path_local_stat_result.stat.exists | bool"
block: block:
- ansible.builtin.include_role: - ansible.builtin.include_role:
name: galaxy/postgres name: galaxy/postgres
tasks_from: migrate_db_to_postgres tasks_from: migrate_db_to_postgres
vars: vars:
postgres_db_migration_request: postgres_db_migration_request:
src: "{{ matrix_mx_puppet_groupme_sqlite_database_path_local }}" src: "{{ matrix_bridge_mx_puppet_groupme_sqlite_database_path_local }}"
dst: "{{ matrix_mx_puppet_groupme_database_connection_string }}" dst: "{{ matrix_bridge_mx_puppet_groupme_database_connection_string }}"
caller: "{{ role_path | basename }}" caller: "{{ role_path | basename }}"
engine_variable_name: 'matrix_mx_puppet_groupme_database_engine' engine_variable_name: 'matrix_bridge_mx_puppet_groupme_database_engine'
engine_old: 'sqlite' engine_old: 'sqlite'
systemd_services_to_stop: ['matrix-mx-puppet-groupme.service'] systemd_services_to_stop: ['matrix-mx-puppet-groupme.service']
- ansible.builtin.set_fact: - ansible.builtin.set_fact:
matrix_mx_puppet_groupme_migration_requires_restart: true matrix_bridge_mx_puppet_groupme_migration_requires_restart: true
- name: Ensure MX Puppet Groupme image is pulled - name: Ensure MX Puppet Groupme image is pulled
community.docker.docker_image_pull: community.docker.docker_image_pull:
name: "{{ matrix_mx_puppet_groupme_container_image }}" name: "{{ matrix_bridge_mx_puppet_groupme_container_image }}"
pull: always pull: always
when: matrix_mx_puppet_groupme_enabled | bool and not matrix_mx_puppet_groupme_container_image_self_build when: matrix_bridge_mx_puppet_groupme_enabled | bool and not matrix_bridge_mx_puppet_groupme_container_image_self_build
register: matrix_mx_puppet_groupme_container_image_pull_result register: matrix_bridge_mx_puppet_groupme_container_image_pull_result
retries: "{{ devture_playbook_help_container_retries_count }}" retries: "{{ devture_playbook_help_container_retries_count }}"
delay: "{{ devture_playbook_help_container_retries_delay }}" delay: "{{ devture_playbook_help_container_retries_delay }}"
until: matrix_mx_puppet_groupme_container_image_pull_result is not failed until: matrix_bridge_mx_puppet_groupme_container_image_pull_result is not failed
- name: Ensure MX Puppet Groupme repository is present on self build - name: Ensure MX Puppet Groupme repository is present on self build
ansible.builtin.git: ansible.builtin.git:
repo: "{{ matrix_mx_puppet_groupme_container_image_self_build_repo }}" repo: "{{ matrix_bridge_mx_puppet_groupme_container_image_self_build_repo }}"
version: "{{ matrix_mx_puppet_groupme_container_image_self_build_repo_version }}" version: "{{ matrix_bridge_mx_puppet_groupme_container_image_self_build_repo_version }}"
dest: "{{ matrix_mx_puppet_groupme_container_src_files_path }}" dest: "{{ matrix_bridge_mx_puppet_groupme_container_src_files_path }}"
force: "yes" force: "yes"
become: true become: true
become_user: "{{ matrix_user_name }}" become_user: "{{ matrix_user_name }}"
register: matrix_mx_puppet_groupme_git_pull_results register: matrix_bridge_mx_puppet_groupme_git_pull_results
when: "matrix_mx_puppet_groupme_enabled | bool and matrix_mx_puppet_groupme_container_image_self_build" when: "matrix_bridge_mx_puppet_groupme_enabled | bool and matrix_bridge_mx_puppet_groupme_container_image_self_build"
- name: Ensure MX Puppet Groupme Docker image is built - name: Ensure MX Puppet Groupme Docker image is built
community.docker.docker_image_build: community.docker.docker_image_build:
name: "{{ matrix_mx_puppet_groupme_container_image }}" name: "{{ matrix_bridge_mx_puppet_groupme_container_image }}"
dockerfile: Dockerfile dockerfile: Dockerfile
path: "{{ matrix_mx_puppet_groupme_container_src_files_path }}" path: "{{ matrix_bridge_mx_puppet_groupme_container_src_files_path }}"
pull: true pull: true
rebuild: "{{ 'always' if matrix_mx_puppet_groupme_git_pull_results.changed | bool else 'never' }}" rebuild: "{{ 'always' if matrix_bridge_mx_puppet_groupme_git_pull_results.changed | bool else 'never' }}"
when: "matrix_mx_puppet_groupme_enabled | bool and matrix_mx_puppet_groupme_container_image_self_build" when: "matrix_bridge_mx_puppet_groupme_enabled | bool and matrix_bridge_mx_puppet_groupme_container_image_self_build"
register: matrix_mx_puppet_groupme_container_image_build_result register: matrix_bridge_mx_puppet_groupme_container_image_build_result
- name: Ensure mx-puppet-groupme config.yaml installed - name: Ensure mx-puppet-groupme config.yaml installed
ansible.builtin.copy: ansible.builtin.copy:
content: "{{ matrix_mx_puppet_groupme_configuration | to_nice_yaml(indent=2, width=999999) }}" content: "{{ matrix_bridge_mx_puppet_groupme_configuration | to_nice_yaml(indent=2, width=999999) }}"
dest: "{{ matrix_mx_puppet_groupme_config_path }}/config.yaml" dest: "{{ matrix_bridge_mx_puppet_groupme_config_path }}/config.yaml"
mode: '0644' mode: '0644'
owner: "{{ matrix_user_name }}" owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}" group: "{{ matrix_group_name }}"
register: matrix_mx_puppet_groupme_config_result register: matrix_bridge_mx_puppet_groupme_config_result
- name: Ensure mx-puppet-groupme groupme-registration.yaml installed - name: Ensure mx-puppet-groupme groupme-registration.yaml installed
ansible.builtin.copy: ansible.builtin.copy:
content: "{{ matrix_mx_puppet_groupme_registration | to_nice_yaml(indent=2, width=999999) }}" content: "{{ matrix_bridge_mx_puppet_groupme_registration | to_nice_yaml(indent=2, width=999999) }}"
dest: "{{ matrix_mx_puppet_groupme_config_path }}/registration.yaml" dest: "{{ matrix_bridge_mx_puppet_groupme_config_path }}/registration.yaml"
mode: '0644' mode: '0644'
owner: "{{ matrix_user_name }}" owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}" group: "{{ matrix_group_name }}"
register: matrix_mx_puppet_groupme_registration_result register: matrix_bridge_mx_puppet_groupme_registration_result
- name: Ensure mx-puppet-groupme container network is created - name: Ensure mx-puppet-groupme container network is created
when: matrix_mx_puppet_groupme_container_network != 'host' when: matrix_bridge_mx_puppet_groupme_container_network != 'host'
community.general.docker_network: community.general.docker_network:
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}" enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_mx_puppet_groupme_container_network }}" name: "{{ matrix_bridge_mx_puppet_groupme_container_network }}"
driver: bridge driver: bridge
driver_options: "{{ devture_systemd_docker_base_container_networks_driver_options }}" driver_options: "{{ devture_systemd_docker_base_container_networks_driver_options }}"
@@ -134,18 +134,18 @@
src: "{{ role_path }}/templates/systemd/matrix-mx-puppet-groupme.service.j2" src: "{{ role_path }}/templates/systemd/matrix-mx-puppet-groupme.service.j2"
dest: "/etc/systemd/system/matrix-mx-puppet-groupme.service" dest: "/etc/systemd/system/matrix-mx-puppet-groupme.service"
mode: '0644' mode: '0644'
register: matrix_mx_puppet_groupme_systemd_service_result register: matrix_bridge_mx_puppet_groupme_systemd_service_result
- name: Determine whether matrix-mx-puppet-groupme needs a restart - name: Determine whether matrix-mx-puppet-groupme needs a restart
ansible.builtin.set_fact: ansible.builtin.set_fact:
matrix_mx_puppet_groupme_restart_necessary: >- matrix_bridge_mx_puppet_groupme_restart_necessary: >-
{{ {{
matrix_mx_puppet_groupme_migration_requires_restart | default(false) matrix_bridge_mx_puppet_groupme_migration_requires_restart | default(false)
or matrix_mx_puppet_groupme_config_result.changed | default(false) or matrix_bridge_mx_puppet_groupme_config_result.changed | default(false)
or matrix_mx_puppet_groupme_registration_result.changed | default(false) or matrix_bridge_mx_puppet_groupme_registration_result.changed | default(false)
or matrix_mx_puppet_groupme_systemd_service_result.changed | default(false) or matrix_bridge_mx_puppet_groupme_systemd_service_result.changed | default(false)
or matrix_mx_puppet_groupme_container_image_pull_result.changed | default(false) or matrix_bridge_mx_puppet_groupme_container_image_pull_result.changed | default(false)
or matrix_mx_puppet_groupme_container_image_build_result.changed | default(false) or matrix_bridge_mx_puppet_groupme_container_image_build_result.changed | default(false)
}} }}
- name: Ensure matrix-mx-puppet-groupme.service restarted, if necessary - name: Ensure matrix-mx-puppet-groupme.service restarted, if necessary
@@ -153,4 +153,4 @@
name: "matrix-mx-puppet-groupme.service" name: "matrix-mx-puppet-groupme.service"
state: restarted state: restarted
daemon_reload: true daemon_reload: true
when: "matrix_mx_puppet_groupme_migration_requires_restart | bool" when: "matrix_bridge_mx_puppet_groupme_migration_requires_restart | bool"
@@ -9,9 +9,9 @@
- name: Check existence of matrix-mx-puppet-groupme service - name: Check existence of matrix-mx-puppet-groupme service
ansible.builtin.stat: ansible.builtin.stat:
path: "/etc/systemd/system/matrix-mx-puppet-groupme.service" path: "/etc/systemd/system/matrix-mx-puppet-groupme.service"
register: matrix_mx_puppet_groupme_service_stat register: matrix_bridge_mx_puppet_groupme_service_stat
- when: matrix_mx_puppet_groupme_service_stat.stat.exists | bool - when: matrix_bridge_mx_puppet_groupme_service_stat.stat.exists | bool
block: block:
- name: Ensure matrix-mx-puppet-groupme is stopped - name: Ensure matrix-mx-puppet-groupme is stopped
ansible.builtin.service: ansible.builtin.service:
@@ -11,14 +11,14 @@
The variable `{{ item.old }}` is deprecated. Please use `{{ item.new }}` instead. The variable `{{ item.old }}` is deprecated. Please use `{{ item.new }}` instead.
when: "lookup('ansible.builtin.varnames', ('^' + item.old + '$'), wantlist=True) | length > 0" when: "lookup('ansible.builtin.varnames', ('^' + item.old + '$'), wantlist=True) | length > 0"
with_items: with_items:
- {'old': 'matrix_mx_puppet_groupme_docker_image_name_prefix', 'new': 'matrix_mx_puppet_groupme_container_image_registry_prefix'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_image_name_prefix', 'new': 'matrix_bridge_mx_puppet_groupme_container_image_registry_prefix'}
- {'old': 'matrix_mx_puppet_groupme_docker_image', 'new': 'matrix_mx_puppet_groupme_container_image'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_image', 'new': 'matrix_bridge_mx_puppet_groupme_container_image'}
- {'old': 'matrix_mx_puppet_groupme_docker_image_force_pull', 'new': 'matrix_mx_puppet_groupme_container_image_force_pull'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_image_force_pull', 'new': 'matrix_bridge_mx_puppet_groupme_container_image_force_pull'}
- {'old': 'matrix_mx_puppet_groupme_docker_image_registry_prefix', 'new': 'matrix_mx_puppet_groupme_container_image_registry_prefix'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_image_registry_prefix', 'new': 'matrix_bridge_mx_puppet_groupme_container_image_registry_prefix'}
- {'old': 'matrix_mx_puppet_groupme_docker_image_registry_prefix_upstream', 'new': 'matrix_mx_puppet_groupme_container_image_registry_prefix_upstream'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_image_registry_prefix_upstream', 'new': 'matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream'}
- {'old': 'matrix_mx_puppet_groupme_docker_image_registry_prefix_upstream_default', 'new': 'matrix_mx_puppet_groupme_container_image_registry_prefix_upstream_default'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_image_registry_prefix_upstream_default', 'new': 'matrix_bridge_mx_puppet_groupme_container_image_registry_prefix_upstream_default'}
- {'old': 'matrix_mx_puppet_groupme_docker_src_files_path', 'new': 'matrix_mx_puppet_groupme_container_src_files_path'} - {'old': 'matrix_bridge_mx_puppet_groupme_docker_src_files_path', 'new': 'matrix_bridge_mx_puppet_groupme_container_src_files_path'}
- {'old': 'matrix_mx_puppet_groupme_container_image_force_pull', 'new': '<removed> (the new community.docker.docker_image_pull module handles this natively)'} - {'old': 'matrix_bridge_mx_puppet_groupme_container_image_force_pull', 'new': '<removed> (the new community.docker.docker_image_pull module handles this natively)'}
- name: Fail if required mx-puppet-groupme settings not defined - name: Fail if required mx-puppet-groupme settings not defined
ansible.builtin.fail: ansible.builtin.fail:
@@ -26,8 +26,8 @@
You need to define a required configuration setting (`{{ item.name }}`). You need to define a required configuration setting (`{{ item.name }}`).
when: "item.when | bool and lookup('vars', item.name, default='') | string | length == 0" when: "item.when | bool and lookup('vars', item.name, default='') | string | length == 0"
with_items: with_items:
- {'name': 'matrix_mx_puppet_groupme_appservice_token', when: true} - {'name': 'matrix_bridge_mx_puppet_groupme_appservice_token', when: true}
- {'name': 'matrix_mx_puppet_groupme_homeserver_address', when: true} - {'name': 'matrix_bridge_mx_puppet_groupme_homeserver_address', when: true}
- {'name': 'matrix_mx_puppet_groupme_homeserver_token', when: true} - {'name': 'matrix_bridge_mx_puppet_groupme_homeserver_token', when: true}
- {'name': 'matrix_mx_puppet_groupme_database_hostname', when: "{{ matrix_mx_puppet_groupme_database_engine == 'postgres' }}"} - {'name': 'matrix_bridge_mx_puppet_groupme_database_hostname', when: "{{ matrix_bridge_mx_puppet_groupme_database_engine == 'postgres' }}"}
- {'name': 'matrix_mx_puppet_groupme_container_network', when: true} - {'name': 'matrix_bridge_mx_puppet_groupme_container_network', when: true}
@@ -2,16 +2,16 @@
bridge: bridge:
# Port to host the bridge on # Port to host the bridge on
# Used for communication between the homeserver and the bridge # Used for communication between the homeserver and the bridge
port: {{ matrix_mx_puppet_groupme_appservice_port }} port: {{ matrix_bridge_mx_puppet_groupme_appservice_port }}
# The host connections to the bridge's webserver are allowed from # The host connections to the bridge's webserver are allowed from
bindAddress: 0.0.0.0 bindAddress: 0.0.0.0
# Public domain of the homeserver # Public domain of the homeserver
domain: {{ matrix_mx_puppet_groupme_homeserver_domain }} domain: {{ matrix_bridge_mx_puppet_groupme_homeserver_domain }}
# Reachable URL of the Matrix homeserver # Reachable URL of the Matrix homeserver
homeserverUrl: {{ matrix_mx_puppet_groupme_homeserver_address }} homeserverUrl: {{ matrix_bridge_mx_puppet_groupme_homeserver_address }}
{% if matrix_mx_puppet_groupme_login_shared_secret != '' %} {% if matrix_bridge_mx_puppet_groupme_login_shared_secret != '' %}
loginSharedSecretMap: loginSharedSecretMap:
{{ matrix_domain }}: {{ matrix_mx_puppet_groupme_login_shared_secret }} {{ matrix_domain }}: {{ matrix_bridge_mx_puppet_groupme_login_shared_secret }}
{% endif %} {% endif %}
# Display name of the bridge bot # Display name of the bridge bot
displayname: GroupMe Puppet Bridge displayname: GroupMe Puppet Bridge
@@ -23,13 +23,13 @@ bridge:
presence: presence:
# Bridge GroupMe online/offline status # Bridge GroupMe online/offline status
enabled: {{ matrix_mx_puppet_groupme_presence_enabled | to_json }} enabled: {{ matrix_bridge_mx_puppet_groupme_presence_enabled | to_json }}
# How often to send status to the homeserver in milliseconds # How often to send status to the homeserver in milliseconds
interval: {{ matrix_mx_puppet_groupme_presence_enabled | to_json }} interval: {{ matrix_bridge_mx_puppet_groupme_presence_enabled | to_json }}
provisioning: provisioning:
# Regex of Matrix IDs allowed to use the puppet bridge # Regex of Matrix IDs allowed to use the puppet bridge
whitelist: {{ matrix_mx_puppet_groupme_provisioning_whitelist|to_json }} whitelist: {{ matrix_bridge_mx_puppet_groupme_provisioning_whitelist|to_json }}
# Allow a specific user # Allow a specific user
#- "@alice:example\\.com" #- "@alice:example\\.com"
# Allow users on a specific homeserver # Allow users on a specific homeserver
@@ -42,7 +42,7 @@ provisioning:
#- "@bob:example\\.com" #- "@bob:example\\.com"
# Disallow users on a specific homeserver # Disallow users on a specific homeserver
#- "@.*:example\\.com" #- "@.*:example\\.com"
blacklist: {{ matrix_mx_puppet_groupme_provisioning_blacklist|to_json }} blacklist: {{ matrix_bridge_mx_puppet_groupme_provisioning_blacklist|to_json }}
relay: relay:
# Regex of Matrix IDs who are allowed to use the bridge in relay mode. # Regex of Matrix IDs who are allowed to use the bridge in relay mode.
@@ -50,28 +50,28 @@ relay:
# multiple Matrix users # multiple Matrix users
# #
# Same format as in provisioning # Same format as in provisioning
whitelist: {{ matrix_mx_puppet_groupme_provisioning_whitelist|to_json }} whitelist: {{ matrix_bridge_mx_puppet_groupme_provisioning_whitelist|to_json }}
blacklist: {{ matrix_mx_puppet_groupme_provisioning_blacklist|to_json }} blacklist: {{ matrix_bridge_mx_puppet_groupme_provisioning_blacklist|to_json }}
selfService: selfService:
# Regex of Matrix IDs who are allowed to use bridge self-servicing (plumbed rooms) # Regex of Matrix IDs who are allowed to use bridge self-servicing (plumbed rooms)
# #
# Same format as in provisioning # Same format as in provisioning
whitelist: {{ matrix_mx_puppet_groupme_provisioning_whitelist|to_json }} whitelist: {{ matrix_bridge_mx_puppet_groupme_provisioning_whitelist|to_json }}
blacklist: {{ matrix_mx_puppet_groupme_provisioning_blacklist|to_json }} blacklist: {{ matrix_bridge_mx_puppet_groupme_provisioning_blacklist|to_json }}
database: database:
{% if matrix_mx_puppet_groupme_database_engine == 'postgres' %} {% if matrix_bridge_mx_puppet_groupme_database_engine == 'postgres' %}
# Use Postgres as a database backend # Use Postgres as a database backend
# If set, will be used instead of SQLite3 # If set, will be used instead of SQLite3
# Connection string to connect to the Postgres instance # Connection string to connect to the Postgres instance
# with username "user", password "pass", host "localhost" and database name "dbname". # with username "user", password "pass", host "localhost" and database name "dbname".
# Modify each value as necessary # Modify each value as necessary
connString: {{ matrix_mx_puppet_groupme_database_connection_string|to_json }} connString: {{ matrix_bridge_mx_puppet_groupme_database_connection_string|to_json }}
{% else %} {% else %}
# Use SQLite3 as a database backend # Use SQLite3 as a database backend
# The name of the database file # The name of the database file
filename: {{ matrix_mx_puppet_groupme_sqlite_database_path_in_container|to_json }} filename: {{ matrix_bridge_mx_puppet_groupme_sqlite_database_path_in_container|to_json }}
{% endif %} {% endif %}
logging: logging:
@@ -1,11 +1,11 @@
#jinja2: lstrip_blocks: True #jinja2: lstrip_blocks: True
[Unit] [Unit]
Description=Matrix Mx Puppet Groupme bridge Description=Matrix Mx Puppet Groupme bridge
{% for service in matrix_mx_puppet_groupme_systemd_required_services_list %} {% for service in matrix_bridge_mx_puppet_groupme_systemd_required_services_list %}
Requires={{ service }} Requires={{ service }}
After={{ service }} After={{ service }}
{% endfor %} {% endfor %}
{% for service in matrix_mx_puppet_groupme_systemd_wanted_services_list %} {% for service in matrix_bridge_mx_puppet_groupme_systemd_wanted_services_list %}
Wants={{ service }} Wants={{ service }}
{% endfor %} {% endfor %}
DefaultDependencies=no DefaultDependencies=no
@@ -22,18 +22,18 @@ ExecStartPre={{ devture_systemd_docker_base_host_command_docker }} create \
--log-driver=none \ --log-driver=none \
--user={{ matrix_user_uid }}:{{ matrix_user_gid }} \ --user={{ matrix_user_uid }}:{{ matrix_user_gid }} \
--cap-drop=ALL \ --cap-drop=ALL \
--network={{ matrix_mx_puppet_groupme_container_network }} \ --network={{ matrix_bridge_mx_puppet_groupme_container_network }} \
-e CONFIG_PATH=/config/config.yaml \ -e CONFIG_PATH=/config/config.yaml \
-e REGISTRATION_PATH=/config/registration.yaml \ -e REGISTRATION_PATH=/config/registration.yaml \
--mount type=bind,src={{ matrix_mx_puppet_groupme_config_path }},dst=/config \ --mount type=bind,src={{ matrix_bridge_mx_puppet_groupme_config_path }},dst=/config \
--mount type=bind,src={{ matrix_mx_puppet_groupme_data_path }},dst=/data \ --mount type=bind,src={{ matrix_bridge_mx_puppet_groupme_data_path }},dst=/data \
{% for arg in matrix_mx_puppet_groupme_container_extra_arguments %} {% for arg in matrix_bridge_mx_puppet_groupme_container_extra_arguments %}
{{ arg }} \ {{ arg }} \
{% endfor %} {% endfor %}
{{ matrix_mx_puppet_groupme_container_image }} {{ matrix_bridge_mx_puppet_groupme_container_image }}
{% if matrix_mx_puppet_groupme_container_network != 'host' %} {% if matrix_bridge_mx_puppet_groupme_container_network != 'host' %}
{% for network in matrix_mx_puppet_groupme_container_additional_networks %} {% for network in matrix_bridge_mx_puppet_groupme_container_additional_networks %}
ExecStartPre={{ devture_systemd_docker_base_host_command_docker }} network connect {{ network }} matrix-mx-puppet-groupme ExecStartPre={{ devture_systemd_docker_base_host_command_docker }} network connect {{ network }} matrix-mx-puppet-groupme
{% endfor %} {% endfor %}
{% endif %} {% endif %}