This is a simplification and a way to make it consistent with
how we do Postgres imports (see 6d89319822
), using
files coming from the server, not from the local machine.
By encouraging people NOT to use local files,
we potentially avoid problems such as #34 (Github issue),
where people would download `media_store` to their Mac's filesystem
and case-sensitivity issues will actually corrupt it.
By not encouraging local files usage, it's less likely that
people would copy (huge) directories to their local machine like that.
development
parent
543b98d24c
commit
76506f34e0
@ -0,0 +1,22 @@
|
||||
# Importing `media_store` data files from an existing installation (optional)
|
||||
|
||||
Run this if you'd like to import your `media_store` files from a previous installation of Matrix Synapse.
|
||||
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Before doing the actual data restore, **you need to upload your media store directory to the server** (any path is okay).
|
||||
|
||||
If you are [Storing Matrix media files on Amazon S3](configuring-playbook-s3.md) (optional), restoring with this tool is not possible right now.
|
||||
As an alternative, you can perform a manual restore using the [AWS CLI tool](https://aws.amazon.com/cli/) (e.g. `aws s3 sync /path/to/server/media_store/. s3://name-of-bucket/`)
|
||||
|
||||
**Note for Mac users**: Due to case-sensitivity issues on certain Mac filesystems (HFS or HFS+), filename corruption may occur if you copy a `media_store` directory to your Mac. If you're transferring a `media_store` directory between 2 servers, make sure you do it directly (from server to server with a tool such as [rsync](https://rsync.samba.org/)), and not by downloading the files to your Mac.
|
||||
|
||||
|
||||
## Importing
|
||||
|
||||
Run this command (make sure to replace `<server-path-to-media_store>` with a path on your server):
|
||||
|
||||
ansible-playbook -i inventory/hosts setup.yml --extra-vars='server_path_media_store=<server-path-to-media_store>' --tags=import-media-store
|
||||
|
||||
**Note**: `<server-path-to-media_store>` must be a file path to a `media_store` directory on the server (not on your local machine!).
|
@ -1,9 +0,0 @@
|
||||
# Restoring `media_store` data files from an existing installation (optional)
|
||||
|
||||
Run this if you'd like to import your `media_store` files from a previous installation of Matrix Synapse.
|
||||
|
||||
Run this command (make sure to replace `<local-path-to-media_store>` with a path on your local machine):
|
||||
|
||||
ansible-playbook -i inventory/hosts setup.yml --extra-vars='local_path_media_store=<local-path-to-media_store>' --tags=import-media-store
|
||||
|
||||
**Note**: `<local-path-to-media_store>` must be a file path to a `media_store` directory on your local machine (not on the server!). This directory's contents are then copied to the server.
|
Loading…
Reference in new issue