Merge branch 'master' into pub.solar
This commit is contained in:
commit
7fc6b574b4
4 changed files with 25 additions and 1 deletions
|
@ -10,6 +10,8 @@ ansible-playbook -i inventory/hosts setup.yml --tags=setup-all
|
|||
|
||||
**Note**: if you don't use SSH keys for authentication, but rather a regular password, you may need to add `--ask-pass` to the above (and all other) Ansible commands.
|
||||
|
||||
**Note**: if you **do** use SSH keys for authentication, **and** use a non-root user to *become* root (sudo), you may need to add `-K` (`--ask-become-pass`) to the above (and all other) Ansible commands.
|
||||
|
||||
The above command **doesn't start any services just yet** (another step does this later - below).
|
||||
|
||||
Feel free to **re-run this setup command any time** you think something is off with the server configuration.
|
||||
|
|
|
@ -14,6 +14,7 @@ Table of contents:
|
|||
- [Purging old data with the Purge History API](#purging-old-data-with-the-purge-history-api)
|
||||
- [Compressing state with rust-synapse-compress-state](#compressing-state-with-rust-synapse-compress-state)
|
||||
|
||||
- [Browse and manipulate the database](#browse-and-manipulate-the-database), for when you really need to take matters into your own hands
|
||||
|
||||
## Purging unused data with synapse-janitor
|
||||
|
||||
|
@ -76,3 +77,23 @@ Don't forget that disk space only ever gets released after a [`FULL` Postgres `V
|
|||
Unfortunately, at this time the playbook can't help you run this **experimental tool**.
|
||||
|
||||
Since it's also experimental, you may wish to stay away from it, or at least [make Postgres backups](./maintenance-postgres.md#backing-up-postgresql) first.
|
||||
|
||||
## Browse and manipulate the database
|
||||
|
||||
When the [matrix admin API](https://github.com/matrix-org/synapse/tree/master/docs/admin_api) and the other tools do not provide a more convenient way, having a look at synapse's postgresql database can satisfy a lot of admins' needs.
|
||||
First, set up an SSH tunnel to your matrix server (skip if it is your local machine):
|
||||
|
||||
```
|
||||
# you may replace 1799 with an arbitrary port unbound on both machines
|
||||
ssh -L 1799:localhost:1799 matrix.DOMAIN
|
||||
```
|
||||
|
||||
Then start up an ephemeral [adminer](https://www.adminer.org/) container on the Matrix server, connecting it to the `matrix` network and linking the postgresql container:
|
||||
|
||||
```
|
||||
docker run --rm --publish 1799:8080 --link matrix-postgres --net matrix adminer
|
||||
```
|
||||
|
||||
You should then be able to browse the adminer database administration GUI at http://localhost:1799/ after entering your DB credentials (found in the `host_vars` or on the server in `{{matrix_synapse_config_dir_path}}/homeserver.yaml` under `database.args`)
|
||||
|
||||
⚠️ Be **very careful** with this, there is **no undo** for impromptu DB operations.
|
||||
|
|
|
@ -88,7 +88,7 @@ matrix_appservice_webhooks_enabled: false
|
|||
# Normally, matrix-nginx-proxy is enabled and nginx can reach matrix-appservice-webhooks over the container network.
|
||||
# If matrix-nginx-proxy is not enabled, or you otherwise have a need for it, you can expose
|
||||
# matrix-appservice-webhooks' client-server port to the local host.
|
||||
matrix_appservice_webhooks_container_http_host_bind_port: "{{ '' if matrix_nginx_proxy_enabled else '127.0.0.1:{{ matrix_appservice_webhooks_matrix_port }}' }}"
|
||||
matrix_appservice_webhooks_container_http_host_bind_port: "{{ '' if matrix_nginx_proxy_enabled else ('127.0.0.1:' ~ matrix_appservice_webhooks_matrix_port) }}"
|
||||
|
||||
matrix_appservice_webhooks_appservice_token: "{{ matrix_synapse_macaroon_secret_key | password_hash('sha512', 'webhook.as.token') | to_uuid }}"
|
||||
|
||||
|
|
|
@ -24,6 +24,7 @@ ExecStart=/usr/bin/docker run --rm --name matrix-riot-web \
|
|||
-v {{ matrix_riot_web_data_path }}/nginx.conf:/etc/nginx/nginx.conf:ro \
|
||||
-v /dev/null:/etc/nginx/conf.d/default.conf:ro \
|
||||
-v {{ matrix_riot_web_data_path }}/config.json:/app/config.json:ro \
|
||||
-v {{ matrix_riot_web_data_path }}/config.json:/app/config.{{ matrix_server_fqn_riot }}.json:ro \
|
||||
{% if matrix_riot_web_embedded_pages_home_path is not none %}
|
||||
-v {{ matrix_riot_web_data_path }}/home.html:/app/home.html:ro \
|
||||
{% endif %}
|
||||
|
|
Loading…
Add table
Reference in a new issue