matrixdotorg/synapse with synapse-s3-storage-provider support
1.7K
keep track from matrixdotorg/synapse with synapse-s3-storage-provider integration.
There are two type of use case:
You can just use is as a normal synapse image. Just add media_storage_providers field in your homeserver.yaml config file and it works :)
Thanks for this blog, I add the script he written to the container and extend it.
For docker-compose user, you can use it just like below:
synapse-s3-cron-upload:
image: xylonx/s3-synapse
entrypoint: /regular-upload.sh
environment:
- PG_USER=
- PG_PASS=
- PG_DB=
- PG_HOST=
- PG_PORT=
- REMAIN_TIME=
- MEDIA_PATH=/data/synapse/media_store/
- AWS_ACCESS_KEY_ID=
- AWS_SECRET_ACCESS_KEY=
- AWS_DEFAULT_REGION=
- BUCKET=
- ENDPOINT=
- WAIT_SECONDS=
volumes:
- /path/to/your/synapse/media_store/:/data/synapse/media_store/
PG_ prefix envs specify the connection options to your synpase database.REMAIN_TIME hints how long you want keep file in your local disk. It works as s3_media_upload update-db $REMAIN_TIMEMEDIA_PATH specifies the synapse media path. It should match to the target of the volumes directive.AWS_ prefix envs hint the access info and are used by boto3.BUCKET and ENDPOINT are used by s3_media_upload script determining the uploaded location.WAIT_SECONDS hints the duration between two uploads. It works as sleep $WAIT_SECONDSIf you have any question, you can contact me by :
Content type
Image
Digest
sha256:39965d9c4…
Size
149 MB
Last updated
almost 4 years ago
docker pull xylonx/s3-synapse