Sfoglia il codice sorgente

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.
pull/754/head
Slavi Pantaleev 5 anni fa
parent
commit
6e1dfb62f0
8 ha cambiato i file con 17 aggiunte e 15 eliminazioni
  1. +3
    -3
      docs/README.md
  2. +2
    -2
      docs/importing-postgres.md
  3. +2
    -2
      docs/importing-synapse-media-store.md
  4. +3
    -3
      docs/importing-synapse-sqlite.md
  5. +2
    -2
      docs/installing.md
  6. +0
    -0
      roles/matrix-postgres/tasks/import_synapse_sqlite_db.yml
  7. +4
    -2
      roles/matrix-postgres/tasks/main.yml
  8. +1
    -1
      roles/matrix-synapse/tasks/main.yml

+ 3
- 3
docs/README.md Vedi File

@@ -10,13 +10,13 @@

- [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 `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)



+ 2
- 2
docs/importing-postgres.md Vedi File

@@ -1,7 +1,7 @@
# 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.
(don't forget to import your `media_store` files as well - see [the importing-media-store guide](importing-media-store.md)).
Run this if you'd like to import your database from a previous installation.
(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


docs/importing-media-store.md → docs/importing-synapse-media-store.md Vedi 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.

@@ -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):

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!).

docs/importing-sqlite.md → docs/importing-synapse-sqlite.md Vedi 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.
(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
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):

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**:


+ 2
- 2
docs/installing.md Vedi 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:

- [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 `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


roles/matrix-postgres/tasks/import_sqlite_db.yml → roles/matrix-postgres/tasks/import_synapse_sqlite_db.yml Vedi File


+ 4
- 2
roles/matrix-postgres/tasks/main.yml Vedi File

@@ -19,10 +19,12 @@
tags:
- 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
tags:
- import-sqlite-db
- import-synapse-sqlite-db

- import_tasks: "{{ role_path }}/tasks/upgrade_postgres.yml"
when: run_postgres_upgrade|bool


+ 1
- 1
roles/matrix-synapse/tasks/main.yml Vedi File

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

- import_tasks: "{{ role_path }}/tasks/register_user.yml"
when: run_synapse_register_user|bool


Caricamento…
Annulla
Salva