mirror of
https://github.com/spantaleev/matrix-docker-ansible-deploy.git
synced 2024-12-22 12:35:51 +00:00
76506f34e0
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.
23 lines
1.1 KiB
Markdown
23 lines
1.1 KiB
Markdown
# Importing an existing SQLite database from another installation (optional)
|
|
|
|
Run this if you'd like to import your database from a previous default installation of Matrix Synapse.
|
|
(don't forget to import your `media_store` files as well - see [the importing-media-store guide](importing-media-store.md)).
|
|
|
|
While this playbook always sets up PostgreSQL, by default a Matrix Synapse installation would run
|
|
using an SQLite database.
|
|
|
|
If you have such a Matrix Synapse setup and wish to migrate it here (and over to PostgreSQL), this command is for you.
|
|
|
|
|
|
## Prerequisites
|
|
|
|
Before doing the actual import, **you need to upload your SQLite database file to the server** (any path is okay).
|
|
|
|
|
|
## Importing
|
|
|
|
Run this command (make sure to replace `<server-path-to-homeserver.db>` with a file path on your server):
|
|
|
|
ansible-playbook -i inventory/hosts setup.yml --extra-vars='server_path_homeserver_db=<server-path-to-homeserver.db>' --tags=import-sqlite-db
|
|
|
|
**Note**: `<server-path-to-homeserver.db>` must be a file path to a `homeserver.db` file on the server (not on your local machine!). |