Merge pull request #2316 from qlyoung/fix-s3-ensure-data-directory

fix s3 storage provider not ensuring data dir
development
Slavi Pantaleev 2 years ago committed by GitHub
commit 9b47a85322
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -61,6 +61,7 @@ matrix_synapse_ext_path: "{{ matrix_synapse_base_path }}/ext"
matrix_synapse_ext_s3_storage_provider_base_path: "{{ matrix_synapse_base_path }}/ext/s3-storage-provider" matrix_synapse_ext_s3_storage_provider_base_path: "{{ matrix_synapse_base_path }}/ext/s3-storage-provider"
matrix_synapse_ext_s3_storage_provider_bin_path: "{{ matrix_synapse_ext_s3_storage_provider_base_path }}/bin" matrix_synapse_ext_s3_storage_provider_bin_path: "{{ matrix_synapse_ext_s3_storage_provider_base_path }}/bin"
matrix_synapse_ext_s3_storage_provider_data_path: "{{ matrix_synapse_ext_s3_storage_provider_base_path }}/data"
matrix_synapse_container_client_api_port: 8008 matrix_synapse_container_client_api_port: 8008

@ -27,7 +27,7 @@
- name: Ensure s3-storage-provider database.yaml file installed - name: Ensure s3-storage-provider database.yaml file installed
ansible.builtin.template: ansible.builtin.template:
src: "{{ role_path }}/templates/synapse/ext/s3-storage-provider/database.yaml.j2" src: "{{ role_path }}/templates/synapse/ext/s3-storage-provider/database.yaml.j2"
dest: "{{ matrix_synapse_ext_s3_storage_provider_base_path }}/data/database.yaml" dest: "{{ matrix_synapse_ext_s3_storage_provider_data_path }}/database.yaml"
mode: 0640 mode: 0640
- name: Ensure s3-storage-provider scripts installed - name: Ensure s3-storage-provider scripts installed

@ -16,6 +16,7 @@
- {path: "{{ matrix_synapse_ext_s3_storage_provider_base_path }}", when: "{{ matrix_synapse_ext_synapse_s3_storage_provider_enabled }}"} - {path: "{{ matrix_synapse_ext_s3_storage_provider_base_path }}", when: "{{ matrix_synapse_ext_synapse_s3_storage_provider_enabled }}"}
- {path: "{{ matrix_synapse_ext_s3_storage_provider_bin_path }}", when: "{{ matrix_synapse_ext_synapse_s3_storage_provider_enabled }}"} - {path: "{{ matrix_synapse_ext_s3_storage_provider_bin_path }}", when: "{{ matrix_synapse_ext_synapse_s3_storage_provider_enabled }}"}
- {path: "{{ matrix_synapse_ext_s3_storage_provider_data_path }}", when: "{{ matrix_synapse_ext_synapse_s3_storage_provider_enabled }}"}
# We handle matrix_synapse_media_store_path elsewhere (in ./synapse/setup_install.yml), # We handle matrix_synapse_media_store_path elsewhere (in ./synapse/setup_install.yml),
# because if it's using Goofys and it's already mounted (from before), # because if it's using Goofys and it's already mounted (from before),

@ -5,7 +5,7 @@
--rm \ --rm \
--env-file={{ matrix_synapse_ext_s3_storage_provider_base_path }}/env \ --env-file={{ matrix_synapse_ext_s3_storage_provider_base_path }}/env \
--mount type=bind,src={{ matrix_synapse_storage_path }},dst=/matrix-media-store-parent,bind-propagation=slave \ --mount type=bind,src={{ matrix_synapse_storage_path }},dst=/matrix-media-store-parent,bind-propagation=slave \
--mount type=bind,src={{ matrix_synapse_ext_s3_storage_provider_base_path }}/data,dst=/data \ --mount type=bind,src={{ matrix_synapse_ext_s3_storage_provider_data_path }},dst=/data \
--workdir=/data \ --workdir=/data \
--network={{ matrix_docker_network }} \ --network={{ matrix_docker_network }} \
--entrypoint=/bin/bash \ --entrypoint=/bin/bash \

@ -6,7 +6,7 @@
--rm \ --rm \
--env-file={{ matrix_synapse_ext_s3_storage_provider_base_path }}/env \ --env-file={{ matrix_synapse_ext_s3_storage_provider_base_path }}/env \
--mount type=bind,src={{ matrix_synapse_storage_path }},dst=/matrix-media-store-parent,bind-propagation=slave \ --mount type=bind,src={{ matrix_synapse_storage_path }},dst=/matrix-media-store-parent,bind-propagation=slave \
--mount type=bind,src={{ matrix_synapse_ext_s3_storage_provider_base_path }}/data,dst=/data \ --mount type=bind,src={{ matrix_synapse_ext_s3_storage_provider_data_path }},dst=/data \
--workdir=/data \ --workdir=/data \
--network={{ matrix_docker_network }} \ --network={{ matrix_docker_network }} \
--entrypoint=/bin/bash \ --entrypoint=/bin/bash \

Loading…
Cancel
Save