diff --git a/group_vars/matrix_servers b/group_vars/matrix_servers index 57e1997e5..462257cb8 100755 --- a/group_vars/matrix_servers +++ b/group_vars/matrix_servers @@ -4631,7 +4631,7 @@ matrix_synapse_federation_enabled: "{{ matrix_homeserver_federation_enabled }}" matrix_synapse_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_synapse_container_image_registry_prefix_upstream_default }}" -matrix_s3_goofys_docker_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_s3_goofys_docker_image_registry_prefix_upstream_default }}" +matrix_s3_goofys_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_s3_goofys_container_image_registry_prefix_upstream_default }}" matrix_synapse_rust_synapse_compress_state_container_image_registry_prefix_upstream: "{{ matrix_container_global_registry_prefix_override if matrix_container_global_registry_prefix_override else matrix_synapse_rust_synapse_compress_state_container_image_registry_prefix_upstream_default }}" diff --git a/roles/custom/matrix-synapse/defaults/main.yml b/roles/custom/matrix-synapse/defaults/main.yml index f0191a1aa..7c487a9fb 100644 --- a/roles/custom/matrix-synapse/defaults/main.yml +++ b/roles/custom/matrix-synapse/defaults/main.yml @@ -1549,11 +1549,11 @@ matrix_synapse_ext_media_repo_enabled: false matrix_s3_media_store_enabled: false matrix_s3_media_store_custom_endpoint_enabled: false -matrix_s3_goofys_docker_image: "{{ matrix_s3_goofys_docker_image_registry_prefix }}ewoutp/goofys:latest" -matrix_s3_goofys_docker_image_registry_prefix: "{{ matrix_s3_goofys_docker_image_registry_prefix_upstream }}" -matrix_s3_goofys_docker_image_registry_prefix_upstream: "{{ matrix_s3_goofys_docker_image_registry_prefix_upstream_default }}" -matrix_s3_goofys_docker_image_registry_prefix_upstream_default: "docker.io/" -matrix_s3_goofys_docker_image_force_pull: "{{ matrix_s3_goofys_docker_image.endswith(':latest') }}" +matrix_s3_goofys_container_image: "{{ matrix_s3_goofys_container_image_registry_prefix }}ewoutp/goofys:latest" +matrix_s3_goofys_container_image_registry_prefix: "{{ matrix_s3_goofys_container_image_registry_prefix_upstream }}" +matrix_s3_goofys_container_image_registry_prefix_upstream: "{{ matrix_s3_goofys_container_image_registry_prefix_upstream_default }}" +matrix_s3_goofys_container_image_registry_prefix_upstream_default: "docker.io/" +matrix_s3_goofys_container_image_force_pull: "{{ matrix_s3_goofys_container_image.endswith(':latest') }}" matrix_s3_media_store_custom_endpoint: "your-custom-endpoint" matrix_s3_media_store_bucket_name: "your-bucket-name" matrix_s3_media_store_aws_access_key: "your-aws-access-key" diff --git a/roles/custom/matrix-synapse/tasks/goofys/setup_install.yml b/roles/custom/matrix-synapse/tasks/goofys/setup_install.yml index 9f70ed5a2..9048e430b 100644 --- a/roles/custom/matrix-synapse/tasks/goofys/setup_install.yml +++ b/roles/custom/matrix-synapse/tasks/goofys/setup_install.yml @@ -16,10 +16,10 @@ - name: Ensure Goofys Docker image is pulled community.docker.docker_image: - name: "{{ matrix_s3_goofys_docker_image }}" + name: "{{ matrix_s3_goofys_container_image }}" source: "{{ 'pull' if ansible_version.major > 2 or ansible_version.minor > 7 else omit }}" - force_source: "{{ matrix_s3_goofys_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_s3_goofys_docker_image_force_pull }}" + force_source: "{{ matrix_s3_goofys_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_s3_goofys_container_image_force_pull }}" register: result retries: "{{ devture_playbook_help_container_retries_count }}" delay: "{{ devture_playbook_help_container_retries_delay }}" diff --git a/roles/custom/matrix-synapse/tasks/validate_config.yml b/roles/custom/matrix-synapse/tasks/validate_config.yml index 4f6e44c93..67d3c5836 100644 --- a/roles/custom/matrix-synapse/tasks/validate_config.yml +++ b/roles/custom/matrix-synapse/tasks/validate_config.yml @@ -47,8 +47,13 @@ - {'old': 'matrix_synapse_caches_autotuning_min_cache_ttl', 'new': 'matrix_synapse_cache_autotuning_min_cache_ttl'} - {'old': 'matrix_synapse_memtotal_kb', 'new': ''} - {'old': 'matrix_synapse_docker_image_name_prefix', 'new': 'matrix_synapse_container_image_registry_prefix'} - - {'old': 'matrix_s3_goofys_docker_image_name_prefix', 'new': 'matrix_s3_goofys_docker_image_registry_prefix'} + - {'old': 'matrix_s3_goofys_docker_image_name_prefix', 'new': 'matrix_s3_goofys_container_image_registry_prefix'} - {'old': 'matrix_synapse_rust_synapse_compress_state_docker_image_name_prefix', 'new': 'matrix_synapse_rust_synapse_compress_state_container_image_registry_prefix'} + - {'old': 'matrix_s3_goofys_docker_image', 'new': 'matrix_s3_goofys_container_image'} + - {'old': 'matrix_s3_goofys_docker_image_force_pull', 'new': 'matrix_s3_goofys_container_image_force_pull'} + - {'old': 'matrix_s3_goofys_docker_image_registry_prefix', 'new': 'matrix_s3_goofys_container_image_registry_prefix'} + - {'old': 'matrix_s3_goofys_docker_image_registry_prefix_upstream', 'new': 'matrix_s3_goofys_container_image_registry_prefix_upstream'} + - {'old': 'matrix_s3_goofys_docker_image_registry_prefix_upstream_default', 'new': 'matrix_s3_goofys_container_image_registry_prefix_upstream_default'} - {'old': 'matrix_synapse_docker_image', 'new': 'matrix_synapse_container_image'} - {'old': 'matrix_synapse_docker_image_name', 'new': 'matrix_synapse_container_image_name'} - {'old': 'matrix_synapse_docker_image_tag', 'new': 'matrix_synapse_container_image_tag'} diff --git a/roles/custom/matrix-synapse/templates/goofys/systemd/matrix-goofys.service.j2 b/roles/custom/matrix-synapse/templates/goofys/systemd/matrix-goofys.service.j2 index 54c2df241..5d7ebe10a 100644 --- a/roles/custom/matrix-synapse/templates/goofys/systemd/matrix-goofys.service.j2 +++ b/roles/custom/matrix-synapse/templates/goofys/systemd/matrix-goofys.service.j2 @@ -25,7 +25,7 @@ ExecStart={{ devture_systemd_docker_base_host_command_docker }} run --rm --name --device=/dev/fuse \ --env-file={{ matrix_synapse_config_dir_path }}/env-goofys \ --entrypoint /bin/sh \ - {{ matrix_s3_goofys_docker_image }} \ + {{ matrix_s3_goofys_container_image }} \ -c 'goofys -f{% if not matrix_s3_media_store_custom_endpoint_enabled %} --storage-class=STANDARD_IA{% endif %}{% if matrix_s3_media_store_custom_endpoint_enabled %} --endpoint={{ matrix_s3_media_store_custom_endpoint }}{% endif %} --region {{ matrix_s3_media_store_region }} --stat-cache-ttl 60m0s --type-cache-ttl 60m0s --dir-mode 0700 --file-mode 0700 {{ matrix_s3_media_store_bucket_name }} /s3' # Allow for some time before starting, so that this can start and media is fully mountable.