matrix-docker-ansible-deploy
matrix-docker-ansible-deploy copied to clipboard
Importing Postgres database fails if dump not publically readable
Describe the bug
If the dump.sql file is not publicly readable then the Postgres database import silently fails.
To Reproduce
Make the dump.sql file on the server mode 0640 and perform ansible-playbook -i inventory/hosts setup.yml --extra-vars='server_path_postgres_dump=/.../dump.sql postgres_default_import_database=synapse' --tags=import-postgres
Expected behavior The import works or the import fails with a clear error message.
Matrix Server:
- OS: Debian GNU/Linux 11
- Architecture amd64
Additional context
Perhaps the import playbook could also check that the database is not empty after the import and warn if it is.