mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2026-02-28 18:03:10 +00:00
Rename _docker_ vars to _container_ across 34 roles
Roles affected: appservice-discord, appservice-irc, beeper-linkedin, heisenbridge, hookshot, mautrix-bluesky, mautrix-discord, mautrix-gmessages, mautrix-googlechat, mautrix-signal, mautrix-slack, mautrix-twitter, mautrix-whatsapp, mautrix-wsproxy, mx-puppet-groupme, mx-puppet-steam, postmoogle, sms, steam, cactus-comments, element, fluffychat, schildichat, conduit, corporal, dendrite, ldap-registration-proxy, media-repo, pantalaimon, prometheus-nginxlog-exporter, registration, sygnal, synapse-admin, user-verification-service. For each role: renamed _docker_image* variables to _container_image* (and _docker_src_files_path to _container_src_files_path where applicable), added deprecation entries in validate_config.yml, and updated group_vars/docs references. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -58,7 +58,7 @@
|
||||
{% endif %}
|
||||
--mount type=bind,src={{ matrix_appservice_irc_data_path }},dst=/data
|
||||
--entrypoint=/bin/sh
|
||||
{{ matrix_appservice_irc_docker_image }}
|
||||
{{ matrix_appservice_irc_container_image }}
|
||||
-c
|
||||
'/usr/local/bin/node /app/lib/scripts/migrate-db-to-pgres.js --dbdir /data --privateKey /data/passkey.pem --connectionString {{ matrix_appservice_irc_database_connection_string }}'
|
||||
register: matrix_appservice_irc_import_nedb_to_postgres_result
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
- {path: "{{ matrix_appservice_irc_base_path }}", when: true}
|
||||
- {path: "{{ matrix_appservice_irc_config_path }}", when: true}
|
||||
- {path: "{{ matrix_appservice_irc_data_path }}", when: true}
|
||||
- {path: "{{ matrix_appservice_irc_docker_src_files_path }}", when: "{{ matrix_appservice_irc_container_image_self_build }}"}
|
||||
- {path: "{{ matrix_appservice_irc_container_src_files_path }}", when: "{{ matrix_appservice_irc_container_image_self_build }}"}
|
||||
when: item.when | bool
|
||||
|
||||
- name: Check if an old passkey file already exists
|
||||
@@ -81,10 +81,10 @@
|
||||
|
||||
- name: Ensure Appservice IRC image is pulled
|
||||
community.docker.docker_image:
|
||||
name: "{{ matrix_appservice_irc_docker_image }}"
|
||||
name: "{{ matrix_appservice_irc_container_image }}"
|
||||
source: "{{ 'pull' if ansible_version.major > 2 or ansible_version.minor > 7 else omit }}"
|
||||
force_source: "{{ matrix_appservice_irc_docker_image_force_pull if ansible_version.major > 2 or ansible_version.minor >= 8 else omit }}"
|
||||
force: "{{ omit if ansible_version.major > 2 or ansible_version.minor >= 8 else matrix_appservice_irc_docker_image_force_pull }}"
|
||||
force_source: "{{ matrix_appservice_irc_container_image_force_pull if ansible_version.major > 2 or ansible_version.minor >= 8 else omit }}"
|
||||
force: "{{ omit if ansible_version.major > 2 or ansible_version.minor >= 8 else matrix_appservice_irc_container_image_force_pull }}"
|
||||
when: "matrix_appservice_irc_enabled | bool and not matrix_appservice_irc_container_image_self_build | bool"
|
||||
register: matrix_appservice_irc_container_image_pull_result
|
||||
retries: "{{ devture_playbook_help_container_retries_count }}"
|
||||
@@ -93,9 +93,9 @@
|
||||
|
||||
- name: Ensure matrix-appservice-irc repository is present when self-building
|
||||
ansible.builtin.git:
|
||||
repo: "{{ matrix_appservice_irc_docker_repo }}"
|
||||
version: "{{ matrix_appservice_irc_docker_repo_version }}"
|
||||
dest: "{{ matrix_appservice_irc_docker_src_files_path }}"
|
||||
repo: "{{ matrix_appservice_irc_container_repo }}"
|
||||
version: "{{ matrix_appservice_irc_container_repo_version }}"
|
||||
dest: "{{ matrix_appservice_irc_container_src_files_path }}"
|
||||
force: "yes"
|
||||
become: true
|
||||
become_user: "{{ matrix_user_name }}"
|
||||
@@ -104,13 +104,13 @@
|
||||
|
||||
- name: Ensure matrix-appservice-irc Docker image is built
|
||||
community.docker.docker_image:
|
||||
name: "{{ matrix_appservice_irc_docker_image }}"
|
||||
name: "{{ matrix_appservice_irc_container_image }}"
|
||||
source: build
|
||||
force_source: "{{ matrix_appservice_irc_git_pull_results.changed if ansible_version.major > 2 or ansible_version.minor >= 8 else omit }}"
|
||||
force: "{{ omit if ansible_version.major > 2 or ansible_version.minor >= 8 else matrix_appservice_irc_git_pull_results.changed }}"
|
||||
build:
|
||||
dockerfile: Dockerfile
|
||||
path: "{{ matrix_appservice_irc_docker_src_files_path }}"
|
||||
path: "{{ matrix_appservice_irc_container_src_files_path }}"
|
||||
pull: true
|
||||
when: "matrix_appservice_irc_enabled | bool and matrix_appservice_irc_container_image_self_build | bool and matrix_appservice_irc_git_pull_results.changed"
|
||||
|
||||
@@ -149,7 +149,7 @@
|
||||
- name: Generate IRC appservice signing key for authenticated media
|
||||
community.docker.docker_container:
|
||||
name: "create-auth-media-jwk-key"
|
||||
image: "{{ matrix_appservice_irc_docker_image }}"
|
||||
image: "{{ matrix_appservice_irc_container_image }}"
|
||||
cleanup: true
|
||||
network_mode: none
|
||||
entrypoint: "/usr/local/bin/node"
|
||||
@@ -210,7 +210,7 @@
|
||||
--mount type=bind,src={{ matrix_appservice_irc_config_path }},dst=/config
|
||||
--mount type=bind,src={{ matrix_appservice_irc_data_path }},dst=/data
|
||||
--entrypoint=/bin/bash
|
||||
{{ matrix_appservice_irc_docker_image }}
|
||||
{{ matrix_appservice_irc_container_image }}
|
||||
-c
|
||||
'node app.js
|
||||
-r
|
||||
|
||||
@@ -6,6 +6,27 @@
|
||||
|
||||
---
|
||||
|
||||
- name: (Deprecation) Catch and report renamed appservice-irc variables
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
Your configuration contains a variable, which now has a different name.
|
||||
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_appservice_irc_container_expose_client_server_api_port', 'new': '<superseded by matrix_appservice_irc_container_http_host_bind_port>'}
|
||||
- {'old': 'matrix_appservice_irc_container_self_build', 'new': 'matrix_appservice_irc_container_image_self_build'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_name_prefix', 'new': 'matrix_appservice_irc_container_image_registry_prefix'}
|
||||
- {'old': 'matrix_appservice_irc_homeserver_media_url', 'new': '<removed; media proxying now uses matrix_appservice_irc_ircService_mediaProxy_publicUrl>'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image', 'new': 'matrix_appservice_irc_container_image'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_force_pull', 'new': 'matrix_appservice_irc_container_image_force_pull'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_registry_prefix', 'new': 'matrix_appservice_irc_container_image_registry_prefix'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_registry_prefix_upstream', 'new': 'matrix_appservice_irc_container_image_registry_prefix_upstream'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_registry_prefix_upstream_default', 'new': 'matrix_appservice_irc_container_image_registry_prefix_upstream_default'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_tag', 'new': 'matrix_appservice_irc_container_image_tag'}
|
||||
- {'old': 'matrix_appservice_irc_docker_repo', 'new': 'matrix_appservice_irc_container_repo'}
|
||||
- {'old': 'matrix_appservice_irc_docker_repo_version', 'new': 'matrix_appservice_irc_container_repo_version'}
|
||||
- {'old': 'matrix_appservice_irc_docker_src_files_path', 'new': 'matrix_appservice_irc_container_src_files_path'}
|
||||
|
||||
- name: Fail if required appservice-irc settings not defined
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
@@ -25,6 +46,7 @@
|
||||
# we'd fail generating the registration.yaml file with a non-helpful error.
|
||||
#
|
||||
# This is a safety check to ensure we fail earlier and in a nicer way.
|
||||
|
||||
- name: Fail if no additional configuration provided
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
@@ -34,18 +56,6 @@
|
||||
Overriding the whole bridge's configuration (`matrix_appservice_irc_configuration`) is yet another possibility.
|
||||
when: "matrix_appservice_irc_configuration.ircService.servers | length == 0"
|
||||
|
||||
- name: (Deprecation) Catch and report renamed appservice-irc variables
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
Your configuration contains a variable, which now has a different name.
|
||||
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_appservice_irc_container_expose_client_server_api_port', 'new': '<superseded by matrix_appservice_irc_container_http_host_bind_port>'}
|
||||
- {'old': 'matrix_appservice_irc_container_self_build', 'new': 'matrix_appservice_irc_container_image_self_build'}
|
||||
- {'old': 'matrix_appservice_irc_docker_image_name_prefix', 'new': 'matrix_appservice_irc_docker_image_registry_prefix'}
|
||||
- {'old': 'matrix_appservice_irc_homeserver_media_url', 'new': '<removed; media proxying now uses matrix_appservice_irc_ircService_mediaProxy_publicUrl>'}
|
||||
|
||||
- name: Fail if matrix_appservice_irc_ircService_mediaProxy_publicUrl_pathPrefix does not start with a slash
|
||||
ansible.builtin.fail:
|
||||
msg: >-
|
||||
|
||||
Reference in New Issue
Block a user