5
0
mirror of https://github.com/spantaleev/matrix-docker-ansible-deploy.git synced 2026-07-17 15:26:41 +00:00

Rename matrix_hookshot_* variables to matrix_bridge_hookshot_*

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:48:51 +03:00
parent 6e4992a2fe
commit 7ccc9c515e
12 changed files with 507 additions and 507 deletions
@@ -9,7 +9,7 @@
- tags:
- reset-hookshot-encryption
block:
- when: matrix_hookshot_enabled | bool
- when: matrix_bridge_hookshot_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/reset_encryption.yml"
- tags:
@@ -20,10 +20,10 @@
- install-hookshot
- install-bridge-hookshot
block:
- when: matrix_hookshot_enabled | bool
- when: matrix_bridge_hookshot_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/validate_config.yml"
- when: matrix_hookshot_enabled | bool
- when: matrix_bridge_hookshot_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_install.yml"
- tags:
@@ -31,5 +31,5 @@
- setup-hookshot
- setup-bridge-hookshot
block:
- when: not matrix_hookshot_enabled | bool
- when: not matrix_bridge_hookshot_enabled | bool
ansible.builtin.include_tasks: "{{ role_path }}/tasks/setup_uninstall.yml"
@@ -8,7 +8,7 @@
ansible.builtin.service:
name: matrix-hookshot
state: stopped
register: matrix_hookshot_stopped
register: matrix_bridge_hookshot_stopped
# `yarn start:resetcrypto` fails, as described here: https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/3868
# Also related to: https://github.com/matrix-org/matrix-hookshot/issues/730
@@ -17,11 +17,11 @@
cmd: |
{{ devture_systemd_docker_base_host_command_docker }} run
--rm
--name={{ matrix_hookshot_identifier }}-reset-crypto
--name={{ matrix_bridge_hookshot_identifier }}-reset-crypto
--user={{ matrix_user_uid }}:{{ matrix_user_gid }}
--cap-drop=ALL
--mount type=bind,src={{ matrix_hookshot_base_path }},dst=/data
{{ matrix_hookshot_container_image }}
--mount type=bind,src={{ matrix_bridge_hookshot_base_path }},dst=/data
{{ matrix_bridge_hookshot_container_image }}
node --require source-map-support/register /usr/bin/matrix-hookshot/App/ResetCryptoStore.js
changed_when: true
@@ -31,4 +31,4 @@
state: started
enabled: true
daemon_reload: true
when: matrix_hookshot_stopped.changed | bool
when: matrix_bridge_hookshot_stopped.changed | bool
@@ -24,50 +24,50 @@
owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}"
with_items:
- {path: "{{ matrix_hookshot_base_path }}", when: true}
- {path: "{{ matrix_hookshot_container_src_files_path }}", when: "{{ matrix_hookshot_container_image_self_build }}"}
- {path: "{{ matrix_bridge_hookshot_base_path }}", when: true}
- {path: "{{ matrix_bridge_hookshot_container_src_files_path }}", when: "{{ matrix_bridge_hookshot_container_image_self_build }}"}
when: item.when | bool
- name: Ensure hookshot image is pulled
community.docker.docker_image_pull:
name: "{{ matrix_hookshot_container_image }}"
name: "{{ matrix_bridge_hookshot_container_image }}"
pull: always
when: not matrix_hookshot_container_image_self_build
register: matrix_hookshot_container_image_pull_result
when: not matrix_bridge_hookshot_container_image_self_build
register: matrix_bridge_hookshot_container_image_pull_result
retries: "{{ devture_playbook_help_container_retries_count }}"
delay: "{{ devture_playbook_help_container_retries_delay }}"
until: matrix_hookshot_container_image_pull_result is not failed
until: matrix_bridge_hookshot_container_image_pull_result is not failed
- name: Ensure hookshot repository is present on self-build
ansible.builtin.git:
repo: "{{ matrix_hookshot_container_image_self_build_repo }}"
dest: "{{ matrix_hookshot_container_src_files_path }}"
version: "{{ matrix_hookshot_container_image_self_build_branch }}"
repo: "{{ matrix_bridge_hookshot_container_image_self_build_repo }}"
dest: "{{ matrix_bridge_hookshot_container_src_files_path }}"
version: "{{ matrix_bridge_hookshot_container_image_self_build_branch }}"
force: "yes"
become: true
become_user: "{{ matrix_user_name }}"
register: matrix_hookshot_git_pull_results
when: "matrix_hookshot_container_image_self_build | bool"
register: matrix_bridge_hookshot_git_pull_results
when: "matrix_bridge_hookshot_container_image_self_build | bool"
- name: Ensure hookshot Docker image is built
community.docker.docker_image_build:
name: "{{ matrix_hookshot_container_image }}"
name: "{{ matrix_bridge_hookshot_container_image }}"
dockerfile: Dockerfile
path: "{{ matrix_hookshot_container_src_files_path }}"
path: "{{ matrix_bridge_hookshot_container_src_files_path }}"
pull: true
rebuild: "{{ 'always' if matrix_hookshot_git_pull_results.changed | bool else 'never' }}"
when: "matrix_hookshot_container_image_self_build | bool"
register: matrix_hookshot_container_image_build_result
rebuild: "{{ 'always' if matrix_bridge_hookshot_git_pull_results.changed | bool else 'never' }}"
when: "matrix_bridge_hookshot_container_image_self_build | bool"
register: matrix_bridge_hookshot_container_image_build_result
- name: Check if hookshot passkey exists
ansible.builtin.stat:
path: "{{ matrix_hookshot_base_path }}/passkey.pem"
path: "{{ matrix_bridge_hookshot_base_path }}/passkey.pem"
register: hookshot_passkey_file
- name: Generate hookshot passkey if it doesn't exist
ansible.builtin.shell:
cmd: "{{ matrix_host_command_openssl }} genpkey -out {{ matrix_hookshot_base_path }}/passkey.pem -outform PEM -algorithm RSA -pkeyopt rsa_keygen_bits:4096"
creates: "{{ matrix_hookshot_base_path }}/passkey.pem"
cmd: "{{ matrix_host_command_openssl }} genpkey -out {{ matrix_bridge_hookshot_base_path }}/passkey.pem -outform PEM -algorithm RSA -pkeyopt rsa_keygen_bits:4096"
creates: "{{ matrix_bridge_hookshot_base_path }}/passkey.pem"
become: true
become_user: "{{ matrix_user_name }}"
when: "not hookshot_passkey_file.stat.exists"
@@ -79,32 +79,32 @@
# See: https://github.com/spantaleev/matrix-docker-ansible-deploy/issues/5033
- name: Ensure hookshot passkey has correct ownership and mode
ansible.builtin.file:
path: "{{ matrix_hookshot_base_path }}/passkey.pem"
path: "{{ matrix_bridge_hookshot_base_path }}/passkey.pem"
state: file
mode: '0600'
owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}"
register: matrix_hookshot_passkey_result
register: matrix_bridge_hookshot_passkey_result
- name: Ensure hookshot config.yml installed if provided
ansible.builtin.copy:
content: "{{ matrix_hookshot_configuration | to_nice_yaml(indent=2, width=999999) }}"
dest: "{{ matrix_hookshot_base_path }}/config.yml"
content: "{{ matrix_bridge_hookshot_configuration | to_nice_yaml(indent=2, width=999999) }}"
dest: "{{ matrix_bridge_hookshot_base_path }}/config.yml"
mode: '0644'
owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}"
register: matrix_hookshot_config_result
register: matrix_bridge_hookshot_config_result
- name: Validate hookshot config.yml
ansible.builtin.command:
cmd: |
{{ devture_systemd_docker_base_host_command_docker }} run
--rm
--name={{ matrix_hookshot_container_url }}-validate
--name={{ matrix_bridge_hookshot_container_url }}-validate
--user={{ matrix_user_uid }}:{{ matrix_user_gid }}
--cap-drop=ALL
--mount type=bind,src={{ matrix_hookshot_base_path }}/config.yml,dst=/config.yml,ro
{{ matrix_hookshot_container_image }} node config/Config.js /config.yml
--mount type=bind,src={{ matrix_bridge_hookshot_base_path }}/config.yml,dst=/config.yml,ro
{{ matrix_bridge_hookshot_container_image }} node config/Config.js /config.yml
register: hookshot_config_validation_result
changed_when: false
@@ -115,59 +115,59 @@
- name: Ensure hookshot registration.yml installed if provided
ansible.builtin.copy:
content: "{{ matrix_hookshot_registration | to_nice_yaml(indent=2, width=999999) }}"
dest: "{{ matrix_hookshot_base_path }}/registration.yml"
content: "{{ matrix_bridge_hookshot_registration | to_nice_yaml(indent=2, width=999999) }}"
dest: "{{ matrix_bridge_hookshot_base_path }}/registration.yml"
mode: '0644'
owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}"
register: matrix_hookshot_registration_result
register: matrix_bridge_hookshot_registration_result
- name: Ensure hookshot github private key file installed if github is enabled
ansible.builtin.copy:
content: "{{ matrix_hookshot_github_private_key }}"
dest: "{{ matrix_hookshot_base_path }}/{{ matrix_hookshot_github_private_key_file }}"
content: "{{ matrix_bridge_hookshot_github_private_key }}"
dest: "{{ matrix_bridge_hookshot_base_path }}/{{ matrix_bridge_hookshot_github_private_key_file }}"
mode: '0400'
owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}"
when: matrix_hookshot_github_enabled | bool and matrix_hookshot_github_private_key|length > 0
register: matrix_hookshot_github_key_result
when: matrix_bridge_hookshot_github_enabled | bool and matrix_bridge_hookshot_github_private_key|length > 0
register: matrix_bridge_hookshot_github_key_result
- name: Ensure matrix-hookshot container network is created
when: matrix_hookshot_container_network != 'host'
when: matrix_bridge_hookshot_container_network != 'host'
community.general.docker_network:
enable_ipv6: "{{ devture_systemd_docker_base_ipv6_enabled }}"
name: "{{ matrix_hookshot_container_network }}"
name: "{{ matrix_bridge_hookshot_container_network }}"
driver: bridge
driver_options: "{{ devture_systemd_docker_base_container_networks_driver_options }}"
- name: Ensure mautrix-hookshot support files installed
ansible.builtin.template:
src: "{{ role_path }}/templates/{{ item }}.j2"
dest: "{{ matrix_hookshot_base_path }}/{{ item }}"
dest: "{{ matrix_bridge_hookshot_base_path }}/{{ item }}"
mode: '0640'
owner: "{{ matrix_user_name }}"
group: "{{ matrix_group_name }}"
with_items:
- labels
register: matrix_hookshot_support_files_result
register: matrix_bridge_hookshot_support_files_result
- name: Ensure matrix-hookshot.service installed
ansible.builtin.template:
src: "{{ role_path }}/templates/systemd/matrix-hookshot.service.j2"
dest: "{{ devture_systemd_docker_base_systemd_path }}/matrix-hookshot.service"
mode: '0644'
register: matrix_hookshot_systemd_service_result
register: matrix_bridge_hookshot_systemd_service_result
- name: Determine whether matrix-hookshot needs a restart
ansible.builtin.set_fact:
matrix_hookshot_restart_necessary: >-
matrix_bridge_hookshot_restart_necessary: >-
{{
matrix_hookshot_config_result.changed | default(false)
or matrix_hookshot_registration_result.changed | default(false)
or matrix_hookshot_github_key_result.changed | default(false)
or matrix_hookshot_passkey_result.changed | default(false)
or matrix_hookshot_support_files_result.changed | default(false)
or matrix_hookshot_systemd_service_result.changed | default(false)
or matrix_hookshot_container_image_pull_result.changed | default(false)
or matrix_hookshot_container_image_build_result.changed | default(false)
matrix_bridge_hookshot_config_result.changed | default(false)
or matrix_bridge_hookshot_registration_result.changed | default(false)
or matrix_bridge_hookshot_github_key_result.changed | default(false)
or matrix_bridge_hookshot_passkey_result.changed | default(false)
or matrix_bridge_hookshot_support_files_result.changed | default(false)
or matrix_bridge_hookshot_systemd_service_result.changed | default(false)
or matrix_bridge_hookshot_container_image_pull_result.changed | default(false)
or matrix_bridge_hookshot_container_image_build_result.changed | default(false)
}}
@@ -9,9 +9,9 @@
- name: Check existence of matrix-hookshot service
ansible.builtin.stat:
path: "{{ devture_systemd_docker_base_systemd_path }}/matrix-hookshot.service"
register: matrix_hookshot_service_stat
register: matrix_bridge_hookshot_service_stat
- when: matrix_hookshot_service_stat.stat.exists | bool
- when: matrix_bridge_hookshot_service_stat.stat.exists | bool
block:
- name: Ensure matrix-hookshot is stopped
ansible.builtin.service:
@@ -13,46 +13,46 @@
Please rename the variable (`{{ item.old }}` -> `{{ item.new }}`) on your configuration file (vars.yml).
when: "lookup('ansible.builtin.varnames', ('^' + item.old + '$'), wantlist=True) | length > 0"
with_items:
- {'old': 'matrix_hookshot_feeds_interval', 'new': 'matrix_hookshot_feeds_pollIntervalSeconds'}
- {'old': 'matrix_hookshot_generic_urlprefix', 'new': 'matrix_hookshot_generic_urlPrefix'}
- {'old': 'matrix_hookshot_generic_allow_js_transformation_functions', 'new': 'matrix_hookshot_generic_allowJsTransformationFunctions'}
- {'old': 'matrix_hookshot_generic_user_id_prefix', 'new': 'matrix_hookshot_generic_userIdPrefix'}
- {'old': 'matrix_hookshot_github_secret', 'new': 'matrix_hookshot_github_webhook_secret'}
- {'old': 'matrix_hookshot_github_appid', 'new': 'matrix_hookshot_github_auth_id'}
- {'old': 'matrix_hookshot_github_oauth_id', 'new': 'matrix_hookshot_github_oauth_client_id'}
- {'old': 'matrix_hookshot_github_oauth_secret', 'new': 'matrix_hookshot_github_oauth_client_secret'}
- {'old': 'matrix_hookshot_github_oauth_uri', 'new': 'matrix_hookshot_github_oauth_redirect_uri'}
- {'old': 'matrix_hookshot_github_ignore_hooks', 'new': 'matrix_hookshot_github_defaultOptions_ignoreHooks'}
- {'old': 'matrix_hookshot_github_command_prefix', 'new': 'matrix_hookshot_github_defaultOptions_commandPrefix'}
- {'old': 'matrix_hookshot_github_showIssueRoomLink', 'new': 'matrix_hookshot_github_defaultOptions_showIssueRoomLink'}
- {'old': 'matrix_hookshot_github_pr_diff', 'new': 'matrix_hookshot_github_defaultOptions_prDiff'}
- {'old': 'matrix_hookshot_github_including_labels', 'new': 'matrix_hookshot_github_defaultOptions_includingLabels'}
- {'old': 'matrix_hookshot_github_excluding_labels', 'new': 'matrix_hookshot_github_defaultOptions_excludingLabels'}
- {'old': 'matrix_hookshot_github_hotlink_prefix', 'new': 'matrix_hookshot_github_defaultOptions_hotlinkIssues_prefix'}
- {'old': 'matrix_hookshot_jira_secret', 'new': 'matrix_hookshot_jira_webhook_secret'}
- {'old': 'matrix_hookshot_jira_oauth_id', 'new': 'matrix_hookshot_jira_oauth_client_id'}
- {'old': 'matrix_hookshot_jira_oauth_secret', 'new': 'matrix_hookshot_jira_oauth_client_secret'}
- {'old': 'matrix_hookshot_jira_oauth_uri', 'new': 'matrix_hookshot_jira_oauth_client_secret'}
- {'old': 'matrix_hookshot_gitlab_secret', 'new': 'matrix_hookshot_gitlab_webhook_secret'}
- {'old': 'matrix_hookshot_ident', 'new': 'matrix_hookshot_identifier'}
- {'old': 'matrix_hookshot_queue_host', 'new': 'matrix_hookshot_cache_redis_host'}
- {'old': 'matrix_hookshot_queue_port', 'new': 'matrix_hookshot_cache_redis_port'}
- {'old': 'matrix_hookshot_experimental_encryption_enabled', 'new': 'matrix_hookshot_encryption_enabled'}
- {'old': 'matrix_hookshot_docker_image_name_prefix', 'new': 'matrix_hookshot_container_image_registry_prefix'}
- {'old': 'matrix_hookshot_provisioning_enabled', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_provisioning_port', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_provisioning_secret', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_provisioning_internal', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_provisioning_hostname', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_provisioning_endpoint', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_container_labels_provisioning_enabled', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_hookshot_widgets_*` variables>'}
- {'old': 'matrix_hookshot_docker_image', 'new': 'matrix_hookshot_container_image'}
- {'old': 'matrix_hookshot_docker_image_force_pull', 'new': 'matrix_hookshot_container_image_force_pull'}
- {'old': 'matrix_hookshot_docker_image_registry_prefix', 'new': 'matrix_hookshot_container_image_registry_prefix'}
- {'old': 'matrix_hookshot_docker_image_registry_prefix_upstream', 'new': 'matrix_hookshot_container_image_registry_prefix_upstream'}
- {'old': 'matrix_hookshot_docker_image_registry_prefix_upstream_default', 'new': 'matrix_hookshot_container_image_registry_prefix_upstream_default'}
- {'old': 'matrix_hookshot_docker_src_files_path', 'new': 'matrix_hookshot_container_src_files_path'}
- {'old': 'matrix_hookshot_container_image_force_pull', 'new': '<removed> (the new community.docker.docker_image_pull module handles this natively)'}
- {'old': 'matrix_bridge_hookshot_feeds_interval', 'new': 'matrix_bridge_hookshot_feeds_pollIntervalSeconds'}
- {'old': 'matrix_bridge_hookshot_generic_urlprefix', 'new': 'matrix_bridge_hookshot_generic_urlPrefix'}
- {'old': 'matrix_bridge_hookshot_generic_allow_js_transformation_functions', 'new': 'matrix_bridge_hookshot_generic_allowJsTransformationFunctions'}
- {'old': 'matrix_bridge_hookshot_generic_user_id_prefix', 'new': 'matrix_bridge_hookshot_generic_userIdPrefix'}
- {'old': 'matrix_bridge_hookshot_github_secret', 'new': 'matrix_bridge_hookshot_github_webhook_secret'}
- {'old': 'matrix_bridge_hookshot_github_appid', 'new': 'matrix_bridge_hookshot_github_auth_id'}
- {'old': 'matrix_bridge_hookshot_github_oauth_id', 'new': 'matrix_bridge_hookshot_github_oauth_client_id'}
- {'old': 'matrix_bridge_hookshot_github_oauth_secret', 'new': 'matrix_bridge_hookshot_github_oauth_client_secret'}
- {'old': 'matrix_bridge_hookshot_github_oauth_uri', 'new': 'matrix_bridge_hookshot_github_oauth_redirect_uri'}
- {'old': 'matrix_bridge_hookshot_github_ignore_hooks', 'new': 'matrix_bridge_hookshot_github_defaultOptions_ignoreHooks'}
- {'old': 'matrix_bridge_hookshot_github_command_prefix', 'new': 'matrix_bridge_hookshot_github_defaultOptions_commandPrefix'}
- {'old': 'matrix_bridge_hookshot_github_showIssueRoomLink', 'new': 'matrix_bridge_hookshot_github_defaultOptions_showIssueRoomLink'}
- {'old': 'matrix_bridge_hookshot_github_pr_diff', 'new': 'matrix_bridge_hookshot_github_defaultOptions_prDiff'}
- {'old': 'matrix_bridge_hookshot_github_including_labels', 'new': 'matrix_bridge_hookshot_github_defaultOptions_includingLabels'}
- {'old': 'matrix_bridge_hookshot_github_excluding_labels', 'new': 'matrix_bridge_hookshot_github_defaultOptions_excludingLabels'}
- {'old': 'matrix_bridge_hookshot_github_hotlink_prefix', 'new': 'matrix_bridge_hookshot_github_defaultOptions_hotlinkIssues_prefix'}
- {'old': 'matrix_bridge_hookshot_jira_secret', 'new': 'matrix_bridge_hookshot_jira_webhook_secret'}
- {'old': 'matrix_bridge_hookshot_jira_oauth_id', 'new': 'matrix_bridge_hookshot_jira_oauth_client_id'}
- {'old': 'matrix_bridge_hookshot_jira_oauth_secret', 'new': 'matrix_bridge_hookshot_jira_oauth_client_secret'}
- {'old': 'matrix_bridge_hookshot_jira_oauth_uri', 'new': 'matrix_bridge_hookshot_jira_oauth_client_secret'}
- {'old': 'matrix_bridge_hookshot_gitlab_secret', 'new': 'matrix_bridge_hookshot_gitlab_webhook_secret'}
- {'old': 'matrix_bridge_hookshot_ident', 'new': 'matrix_bridge_hookshot_identifier'}
- {'old': 'matrix_bridge_hookshot_queue_host', 'new': 'matrix_bridge_hookshot_cache_redis_host'}
- {'old': 'matrix_bridge_hookshot_queue_port', 'new': 'matrix_bridge_hookshot_cache_redis_port'}
- {'old': 'matrix_bridge_hookshot_experimental_encryption_enabled', 'new': 'matrix_bridge_hookshot_encryption_enabled'}
- {'old': 'matrix_bridge_hookshot_docker_image_name_prefix', 'new': 'matrix_bridge_hookshot_container_image_registry_prefix'}
- {'old': 'matrix_bridge_hookshot_provisioning_enabled', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_provisioning_port', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_provisioning_secret', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_provisioning_internal', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_provisioning_hostname', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_provisioning_endpoint', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_container_labels_provisioning_enabled', 'new': '<removed - see https://github.com/matrix-org/matrix-hookshot/pull/931 and the `matrix_bridge_hookshot_widgets_*` variables>'}
- {'old': 'matrix_bridge_hookshot_docker_image', 'new': 'matrix_bridge_hookshot_container_image'}
- {'old': 'matrix_bridge_hookshot_docker_image_force_pull', 'new': 'matrix_bridge_hookshot_container_image_force_pull'}
- {'old': 'matrix_bridge_hookshot_docker_image_registry_prefix', 'new': 'matrix_bridge_hookshot_container_image_registry_prefix'}
- {'old': 'matrix_bridge_hookshot_docker_image_registry_prefix_upstream', 'new': 'matrix_bridge_hookshot_container_image_registry_prefix_upstream'}
- {'old': 'matrix_bridge_hookshot_docker_image_registry_prefix_upstream_default', 'new': 'matrix_bridge_hookshot_container_image_registry_prefix_upstream_default'}
- {'old': 'matrix_bridge_hookshot_docker_src_files_path', 'new': 'matrix_bridge_hookshot_container_src_files_path'}
- {'old': 'matrix_bridge_hookshot_container_image_force_pull', 'new': '<removed> (the new community.docker.docker_image_pull module handles this natively)'}
- name: Fail if required Hookshot settings not defined
ansible.builtin.fail:
@@ -60,57 +60,57 @@
You need to define a required configuration setting (`{{ item }}`).
when: "lookup('vars', item, default='') == ''"
with_items:
- "matrix_hookshot_appservice_token"
- "matrix_hookshot_homeserver_address"
- "matrix_hookshot_homeserver_token"
- "matrix_hookshot_container_network"
- "matrix_bridge_hookshot_appservice_token"
- "matrix_bridge_hookshot_homeserver_address"
- "matrix_bridge_hookshot_homeserver_token"
- "matrix_bridge_hookshot_container_network"
- name: Fail if required GitHub settings not defined
ansible.builtin.fail:
msg: >-
You need to define a required configuration setting (`{{ item }}`) to enable GitHub.
when: "matrix_hookshot_github_enabled and lookup('vars', item, default='') == ''"
when: "matrix_bridge_hookshot_github_enabled and lookup('vars', item, default='') == ''"
with_items:
- "matrix_hookshot_github_auth_id"
- "matrix_hookshot_github_webhook_secret"
- "matrix_bridge_hookshot_github_auth_id"
- "matrix_bridge_hookshot_github_webhook_secret"
- name: Fail if required GitHub OAuth settings not defined
ansible.builtin.fail:
msg: >-
You need to define a required configuration setting (`{{ item }}`) to enable GitHub OAuth.
when: "matrix_hookshot_github_oauth_enabled and lookup('vars', item, default='') == ''"
when: "matrix_bridge_hookshot_github_oauth_enabled and lookup('vars', item, default='') == ''"
with_items:
- "matrix_hookshot_github_oauth_client_id"
- "matrix_hookshot_github_oauth_client_secret"
- "matrix_bridge_hookshot_github_oauth_client_id"
- "matrix_bridge_hookshot_github_oauth_client_secret"
- name: Fail if required Jira settings not defined
ansible.builtin.fail:
msg: >-
You need to define a required configuration setting (`{{ item }}`) to enable Jira.
when: "matrix_hookshot_jira_enabled and lookup('vars', item, default='') == ''"
when: "matrix_bridge_hookshot_jira_enabled and lookup('vars', item, default='') == ''"
with_items:
- "matrix_hookshot_jira_webhook_secret"
- "matrix_bridge_hookshot_jira_webhook_secret"
- name: Fail if required Jira OAuth settings not defined
ansible.builtin.fail:
msg: >-
You need to define a required configuration setting (`{{ item }}`) to enable Jira OAuth.
when: "matrix_hookshot_jira_oauth_enabled and lookup('vars', item, default='') == ''"
when: "matrix_bridge_hookshot_jira_oauth_enabled and lookup('vars', item, default='') == ''"
with_items:
- "matrix_hookshot_jira_oauth_client_id"
- "matrix_hookshot_jira_oauth_client_secret"
- "matrix_bridge_hookshot_jira_oauth_client_id"
- "matrix_bridge_hookshot_jira_oauth_client_secret"
- name: Fail if required Figma settings not defined
ansible.builtin.fail:
msg: >-
You need to define at least one Figma instance in `matrix_hookshot_figma_instances` to enable Figma.
when: "matrix_hookshot_figma_enabled and matrix_hookshot_figma_instances | length == 0"
You need to define at least one Figma instance in `matrix_bridge_hookshot_figma_instances` to enable Figma.
when: "matrix_bridge_hookshot_figma_enabled and matrix_bridge_hookshot_figma_instances | length == 0"
- name: Fail if no Redis queue enabled when Hookshot encryption is enabled
ansible.builtin.fail:
msg: >-
You need to define a required configuration setting (`matrix_hookshot_cache_redis*`) to enable Hookshot encryption.
when: "matrix_hookshot_encryption_enabled and matrix_hookshot_cache_redisUri == ''"
You need to define a required configuration setting (`matrix_bridge_hookshot_cache_redis*`) to enable Hookshot encryption.
when: "matrix_bridge_hookshot_encryption_enabled and matrix_bridge_hookshot_cache_redisUri == ''"
- name: (Deprecation) Catch and report old metrics usage
ansible.builtin.fail:
@@ -121,6 +121,6 @@
We now recommend exposing Hookshot metrics in another way, from another URL.
Refer to the changelog for more details: https://github.com/spantaleev/matrix-docker-ansible-deploy/blob/master/CHANGELOG.md#2022-06-22
with_items:
- matrix_hookshot_proxy_metrics
- matrix_hookshot_metrics_endpoint
- matrix_bridge_hookshot_proxy_metrics
- matrix_bridge_hookshot_metrics_endpoint
when: "lookup('ansible.builtin.varnames', ('^' + item + '$'), wantlist=True) | length > 0"