mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2026-02-28 18:03:10 +00:00
Rename matrix-appservice-draupnir-for-all _docker_ vars to _container_
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -3177,7 +3177,7 @@ matrix_appservice_draupnir_for_all_systemd_required_services_list_auto: |
|
|||||||
([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_draupnir_for_all_database_hostname == postgres_connection_hostname) else [])
|
([postgres_identifier ~ '.service'] if (postgres_enabled and matrix_appservice_draupnir_for_all_database_hostname == postgres_connection_hostname) else [])
|
||||||
}}
|
}}
|
||||||
|
|
||||||
matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream_default }}"
|
matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream_default }}"
|
||||||
|
|
||||||
matrix_appservice_draupnir_for_all_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
|
matrix_appservice_draupnir_for_all_container_image_self_build: "{{ matrix_architecture not in ['amd64', 'arm64'] }}"
|
||||||
|
|
||||||
|
|||||||
@@ -17,16 +17,16 @@ matrix_appservice_draupnir_for_all_version: "v2.9.0"
|
|||||||
matrix_appservice_draupnir_for_all_container_image_self_build: false
|
matrix_appservice_draupnir_for_all_container_image_self_build: false
|
||||||
matrix_appservice_draupnir_for_all_container_image_self_build_repo: "https://github.com/the-draupnir-project/Draupnir.git"
|
matrix_appservice_draupnir_for_all_container_image_self_build_repo: "https://github.com/the-draupnir-project/Draupnir.git"
|
||||||
|
|
||||||
matrix_appservice_draupnir_for_all_docker_image_registry_prefix: "{{ 'localhost/' if matrix_appservice_draupnir_for_all_container_image_self_build else matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream }}"
|
matrix_appservice_draupnir_for_all_container_image_registry_prefix: "{{ 'localhost/' if matrix_appservice_draupnir_for_all_container_image_self_build else matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream }}"
|
||||||
matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream: "{{ matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream_default }}"
|
matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream: "{{ matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream_default }}"
|
||||||
matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream_default: "docker.io/"
|
matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream_default: "docker.io/"
|
||||||
matrix_appservice_draupnir_for_all_docker_image: "{{ matrix_appservice_draupnir_for_all_docker_image_registry_prefix }}gnuxie/draupnir:{{ matrix_appservice_draupnir_for_all_version }}"
|
matrix_appservice_draupnir_for_all_container_image: "{{ matrix_appservice_draupnir_for_all_container_image_registry_prefix }}gnuxie/draupnir:{{ matrix_appservice_draupnir_for_all_version }}"
|
||||||
matrix_appservice_draupnir_for_all_docker_image_force_pull: "{{ matrix_appservice_draupnir_for_all_docker_image.endswith(':latest') }}"
|
matrix_appservice_draupnir_for_all_container_image_force_pull: "{{ matrix_appservice_draupnir_for_all_container_image.endswith(':latest') }}"
|
||||||
|
|
||||||
matrix_appservice_draupnir_for_all_base_path: "{{ matrix_base_data_path }}/draupnir-for-all"
|
matrix_appservice_draupnir_for_all_base_path: "{{ matrix_base_data_path }}/draupnir-for-all"
|
||||||
matrix_appservice_draupnir_for_all_config_path: "{{ matrix_appservice_draupnir_for_all_base_path }}/config"
|
matrix_appservice_draupnir_for_all_config_path: "{{ matrix_appservice_draupnir_for_all_base_path }}/config"
|
||||||
matrix_appservice_draupnir_for_all_data_path: "{{ matrix_appservice_draupnir_for_all_base_path }}/data"
|
matrix_appservice_draupnir_for_all_data_path: "{{ matrix_appservice_draupnir_for_all_base_path }}/data"
|
||||||
matrix_appservice_draupnir_for_all_docker_src_files_path: "{{ matrix_appservice_draupnir_for_all_base_path }}/docker-src"
|
matrix_appservice_draupnir_for_all_container_src_files_path: "{{ matrix_appservice_draupnir_for_all_base_path }}/docker-src"
|
||||||
|
|
||||||
matrix_appservice_draupnir_for_all_container_network: ""
|
matrix_appservice_draupnir_for_all_container_network: ""
|
||||||
|
|
||||||
|
|||||||
@@ -22,15 +22,15 @@
|
|||||||
- {path: "{{ matrix_appservice_draupnir_for_all_base_path }}", when: true}
|
- {path: "{{ matrix_appservice_draupnir_for_all_base_path }}", when: true}
|
||||||
- {path: "{{ matrix_appservice_draupnir_for_all_config_path }}", when: true}
|
- {path: "{{ matrix_appservice_draupnir_for_all_config_path }}", when: true}
|
||||||
- {path: "{{ matrix_appservice_draupnir_for_all_data_path }}", when: true}
|
- {path: "{{ matrix_appservice_draupnir_for_all_data_path }}", when: true}
|
||||||
- {path: "{{ matrix_appservice_draupnir_for_all_docker_src_files_path }}", when: "{{ matrix_appservice_draupnir_for_all_container_image_self_build }}"}
|
- {path: "{{ matrix_appservice_draupnir_for_all_container_src_files_path }}", when: "{{ matrix_appservice_draupnir_for_all_container_image_self_build }}"}
|
||||||
when: "item.when | bool"
|
when: "item.when | bool"
|
||||||
|
|
||||||
- name: Ensure Draupnir Docker image is pulled
|
- name: Ensure Draupnir Docker image is pulled
|
||||||
community.docker.docker_image:
|
community.docker.docker_image:
|
||||||
name: "{{ matrix_appservice_draupnir_for_all_docker_image }}"
|
name: "{{ matrix_appservice_draupnir_for_all_container_image }}"
|
||||||
source: "{{ 'pull' if ansible_version.major > 2 or ansible_version.minor > 7 else omit }}"
|
source: "{{ 'pull' if ansible_version.major > 2 or ansible_version.minor > 7 else omit }}"
|
||||||
force_source: "{{ matrix_appservice_draupnir_for_all_docker_image_force_pull if ansible_version.major > 2 or ansible_version.minor >= 8 else omit }}"
|
force_source: "{{ matrix_appservice_draupnir_for_all_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_draupnir_for_all_docker_image_force_pull }}"
|
force: "{{ omit if ansible_version.major > 2 or ansible_version.minor >= 8 else matrix_appservice_draupnir_for_all_container_image_force_pull }}"
|
||||||
when: "not matrix_appservice_draupnir_for_all_container_image_self_build | bool"
|
when: "not matrix_appservice_draupnir_for_all_container_image_self_build | bool"
|
||||||
register: matrix_appservice_draupnir_for_all_container_image_pull_result
|
register: matrix_appservice_draupnir_for_all_container_image_pull_result
|
||||||
retries: "{{ devture_playbook_help_container_retries_count }}"
|
retries: "{{ devture_playbook_help_container_retries_count }}"
|
||||||
@@ -40,8 +40,8 @@
|
|||||||
- name: Ensure Draupnir repository is present on self-build
|
- name: Ensure Draupnir repository is present on self-build
|
||||||
ansible.builtin.git:
|
ansible.builtin.git:
|
||||||
repo: "{{ matrix_appservice_draupnir_for_all_container_image_self_build_repo }}"
|
repo: "{{ matrix_appservice_draupnir_for_all_container_image_self_build_repo }}"
|
||||||
dest: "{{ matrix_appservice_draupnir_for_all_docker_src_files_path }}"
|
dest: "{{ matrix_appservice_draupnir_for_all_container_src_files_path }}"
|
||||||
version: "{{ matrix_appservice_draupnir_for_all_docker_image.split(':')[1] }}"
|
version: "{{ matrix_appservice_draupnir_for_all_container_image.split(':')[1] }}"
|
||||||
force: "yes"
|
force: "yes"
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ matrix_user_name }}"
|
become_user: "{{ matrix_user_name }}"
|
||||||
@@ -50,12 +50,12 @@
|
|||||||
|
|
||||||
- name: Ensure Draupnir Docker image is built
|
- name: Ensure Draupnir Docker image is built
|
||||||
community.docker.docker_image:
|
community.docker.docker_image:
|
||||||
name: "{{ matrix_appservice_draupnir_for_all_docker_image }}"
|
name: "{{ matrix_appservice_draupnir_for_all_container_image }}"
|
||||||
source: build
|
source: build
|
||||||
force_source: "{{ matrix_appservice_draupnir_for_all_git_pull_results.changed }}"
|
force_source: "{{ matrix_appservice_draupnir_for_all_git_pull_results.changed }}"
|
||||||
build:
|
build:
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
path: "{{ matrix_appservice_draupnir_for_all_docker_src_files_path }}"
|
path: "{{ matrix_appservice_draupnir_for_all_container_src_files_path }}"
|
||||||
pull: true
|
pull: true
|
||||||
when: "matrix_appservice_draupnir_for_all_container_image_self_build | bool"
|
when: "matrix_appservice_draupnir_for_all_container_image_self_build | bool"
|
||||||
|
|
||||||
|
|||||||
@@ -7,14 +7,6 @@
|
|||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
- name: Fail if required matrix-bot-draupnir variables are undefined
|
|
||||||
ansible.builtin.fail:
|
|
||||||
msg: "The `{{ item }}` variable must be defined and have a non-null value."
|
|
||||||
with_items:
|
|
||||||
- "matrix_appservice_draupnir_for_all_config_adminRoom"
|
|
||||||
- "matrix_bot_draupnir_container_network"
|
|
||||||
when: "lookup('vars', item, default='') == '' or lookup('vars', item, default='') is none"
|
|
||||||
|
|
||||||
- name: (Deprecation) Catch and report renamed matrix-appservice-draupnir-for-all settings
|
- name: (Deprecation) Catch and report renamed matrix-appservice-draupnir-for-all settings
|
||||||
ansible.builtin.fail:
|
ansible.builtin.fail:
|
||||||
msg: >-
|
msg: >-
|
||||||
@@ -22,6 +14,20 @@
|
|||||||
Please rename the variable (`{{ item.old }}` -> `{{ item.new }}`) on your configuration file (vars.yml).
|
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"
|
when: "lookup('ansible.builtin.varnames', ('^' + item.old + '$'), wantlist=True) | length > 0"
|
||||||
with_items:
|
with_items:
|
||||||
- {'old': 'matrix_appservice_draupnir_for_all_docker_image_name_prefix', 'new': 'matrix_appservice_draupnir_for_all_docker_image_registry_prefix'}
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_image_name_prefix', 'new': 'matrix_appservice_draupnir_for_all_container_image_registry_prefix'}
|
||||||
- {'old': 'matrix_appservice_draupnir_for_all_enable_room_state_backing_store', 'new': 'matrix_appservice_draupnir_for_all_config_roomStateBackingStore_enabled'}
|
- {'old': 'matrix_appservice_draupnir_for_all_enable_room_state_backing_store', 'new': 'matrix_appservice_draupnir_for_all_config_roomStateBackingStore_enabled'}
|
||||||
- {'old': 'matrix_appservice_draupnir_for_all_master_control_room_alias', 'new': 'matrix_appservice_draupnir_for_all_config_adminRoom'}
|
- {'old': 'matrix_appservice_draupnir_for_all_master_control_room_alias', 'new': 'matrix_appservice_draupnir_for_all_config_adminRoom'}
|
||||||
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_image', 'new': 'matrix_appservice_draupnir_for_all_container_image'}
|
||||||
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_image_force_pull', 'new': 'matrix_appservice_draupnir_for_all_container_image_force_pull'}
|
||||||
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_image_registry_prefix', 'new': 'matrix_appservice_draupnir_for_all_container_image_registry_prefix'}
|
||||||
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream', 'new': 'matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream'}
|
||||||
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_image_registry_prefix_upstream_default', 'new': 'matrix_appservice_draupnir_for_all_container_image_registry_prefix_upstream_default'}
|
||||||
|
- {'old': 'matrix_appservice_draupnir_for_all_docker_src_files_path', 'new': 'matrix_appservice_draupnir_for_all_container_src_files_path'}
|
||||||
|
|
||||||
|
- name: Fail if required matrix-bot-draupnir variables are undefined
|
||||||
|
ansible.builtin.fail:
|
||||||
|
msg: "The `{{ item }}` variable must be defined and have a non-null value."
|
||||||
|
with_items:
|
||||||
|
- "matrix_appservice_draupnir_for_all_config_adminRoom"
|
||||||
|
- "matrix_bot_draupnir_container_network"
|
||||||
|
when: "lookup('vars', item, default='') == '' or lookup('vars', item, default='') is none"
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ ExecStartPre={{ devture_systemd_docker_base_host_command_docker }} create \
|
|||||||
{% for arg in matrix_appservice_draupnir_for_all_container_extra_arguments %}
|
{% for arg in matrix_appservice_draupnir_for_all_container_extra_arguments %}
|
||||||
{{ arg }} \
|
{{ arg }} \
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{{ matrix_appservice_draupnir_for_all_docker_image }} \
|
{{ matrix_appservice_draupnir_for_all_container_image }} \
|
||||||
appservice -c /data/config/production-appservice.yaml -f /data/config/draupnir-for-all-registration.yaml -p {{ matrix_appservice_draupnir_for_all_appservice_port }} --draupnir-config /data/config/production-bots.yaml
|
appservice -c /data/config/production-appservice.yaml -f /data/config/draupnir-for-all-registration.yaml -p {{ matrix_appservice_draupnir_for_all_appservice_port }} --draupnir-config /data/config/production-bots.yaml
|
||||||
|
|
||||||
{% for network in matrix_appservice_draupnir_for_all_container_additional_networks %}
|
{% for network in matrix_appservice_draupnir_for_all_container_additional_networks %}
|
||||||
|
|||||||
Reference in New Issue
Block a user