Rename some doc files and commands related to importing

Since we'll likely have generic SQLite database importing
via [pgloader](https://pgloader.io/) for migrating bridge
databases from SQLite to Postgres, we'd rather avoid
calling the "import Synapse SQLite database" command
as just `--tags=import-sqlite-db`.

Similarly, for the media store, we'd like to mention that it's
related to Synapse as well.

We'd like to be more explicit, so as to be less confusing,
especially in light of other homeserver implementations
coming in the future.
This commit is contained in:
Slavi Pantaleev 2020-12-14 01:48:36 +02:00
parent 9dc023c558
commit 6e1dfb62f0
8 changed files with 17 additions and 15 deletions

View File

@ -10,13 +10,13 @@
- [Installing](installing.md) - [Installing](installing.md)
- **Importing data from another Synapse server installation** - **Importing data from another server installation**
- [Importing an existing SQLite database (from another installation)](importing-sqlite.md) (optional) - [Importing an existing SQLite database (from another Synapse installation)](importing-synapse-sqlite.md) (optional)
- [Importing an existing Postgres database (from another installation)](importing-postgres.md) (optional) - [Importing an existing Postgres database (from another installation)](importing-postgres.md) (optional)
- [Importing `media_store` data files from an existing installation](importing-media-store.md) (optional) - [Importing `media_store` data files from an existing Synapse installation](importing-synapse-media-store.md) (optional)
- [Registering users](registering-users.md) - [Registering users](registering-users.md)

View File

@ -1,7 +1,7 @@
# Importing an existing Postgres database from another installation (optional) # Importing an existing Postgres database from another installation (optional)
Run this if you'd like to import your database from a previous installation of Synapse. Run this if you'd like to import your database from a previous installation.
(don't forget to import your `media_store` files as well - see [the importing-media-store guide](importing-media-store.md)). (don't forget to import your Synapse `media_store` files as well - see [the importing-synape-media-store guide](importing-synapse-media-store.md)).
## Prerequisites ## Prerequisites

View File

@ -1,4 +1,4 @@
# Importing `media_store` data files from an existing installation (optional) # Importing `media_store` data files from an existing Synapse installation (optional)
Run this if you'd like to import your `media_store` files from a previous installation of Synapse. Run this if you'd like to import your `media_store` files from a previous installation of Synapse.
@ -17,6 +17,6 @@ As an alternative, you can perform a manual restore using the [AWS CLI tool](htt
Run this command (make sure to replace `<server-path-to-media_store>` with a path on your server): 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 ansible-playbook -i inventory/hosts setup.yml --extra-vars='server_path_media_store=<server-path-to-media_store>' --tags=import-synapse-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!). **Note**: `<server-path-to-media_store>` must be a file path to a `media_store` directory on the server (not on your local machine!).

View File

@ -1,7 +1,7 @@
# Importing an existing SQLite database from another installation (optional) # Importing an existing SQLite database from another Synapse installation (optional)
Run this if you'd like to import your database from a previous default installation of Synapse. Run this if you'd like to import your database from a previous default installation of Synapse.
(don't forget to import your `media_store` files as well - see [the importing-media-store guide](importing-media-store.md)). (don't forget to import your `media_store` files as well - see [the importing-synapse-media-store guide](importing-synapse-media-store.md)).
While this playbook always sets up PostgreSQL, by default a Synapse installation would run While this playbook always sets up PostgreSQL, by default a Synapse installation would run
using an SQLite database. using an SQLite database.
@ -18,7 +18,7 @@ Before doing the actual import, **you need to upload your SQLite database file t
Run this command (make sure to replace `<server-path-to-homeserver.db>` with a file path on your server): 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 ansible-playbook -i inventory/hosts setup.yml --extra-vars='server_path_homeserver_db=<server-path-to-homeserver.db>' --tags=import-synapse-sqlite-db
**Notes**: **Notes**:

View File

@ -21,11 +21,11 @@ Feel free to **re-run this setup command any time** you think something is off w
After installing, but before starting the services, you may want to do additional things like: After installing, but before starting the services, you may want to do additional things like:
- [Importing an existing SQLite database (from another installation)](importing-sqlite.md) (optional) - [Importing an existing SQLite database (from another Synapse installation)](importing-synapse-sqlite.md) (optional)
- [Importing an existing Postgres database (from another installation)](importing-postgres.md) (optional) - [Importing an existing Postgres database (from another installation)](importing-postgres.md) (optional)
- [Importing `media_store` data files from an existing installation](importing-media-store.md) (optional) - [Importing `media_store` data files from an existing Synapse installation](importing-synapse-media-store.md) (optional)
## Starting the services ## Starting the services

View File

@ -19,10 +19,12 @@
tags: tags:
- import-postgres - import-postgres
- import_tasks: "{{ role_path }}/tasks/import_sqlite_db.yml" # The `run_postgres_import_sqlite_db` variable had better be renamed to be consistent,
# but that's a breaking change which may cause trouble for people.
- import_tasks: "{{ role_path }}/tasks/import_synapse_sqlite_db.yml"
when: run_postgres_import_sqlite_db|bool when: run_postgres_import_sqlite_db|bool
tags: tags:
- import-sqlite-db - import-synapse-sqlite-db
- import_tasks: "{{ role_path }}/tasks/upgrade_postgres.yml" - import_tasks: "{{ role_path }}/tasks/upgrade_postgres.yml"
when: run_postgres_upgrade|bool when: run_postgres_upgrade|bool

View File

@ -17,7 +17,7 @@
- import_tasks: "{{ role_path }}/tasks/import_media_store.yml" - import_tasks: "{{ role_path }}/tasks/import_media_store.yml"
when: run_synapse_import_media_store|bool when: run_synapse_import_media_store|bool
tags: tags:
- import-media-store - import-synapse-media-store
- import_tasks: "{{ role_path }}/tasks/register_user.yml" - import_tasks: "{{ role_path }}/tasks/register_user.yml"
when: run_synapse_register_user|bool when: run_synapse_register_user|bool