Now supports PostgreSQL backend.
We support PostgreSQL 18 and previous versions.
If the postgresql*-client is not updated promptly, please create an issue to inform us.
Set to postgresql switch to PostgreSQL database.
Default: sqlite
PostgreSQL host, required.
PostgreSQL port.
Default: 5432
PostgreSQL database name.
Default: vaultwarden
PostgreSQL username.
Default: vaultwarden
PostgreSQL password, required.
The login information will be saved in the ~/.pgpass file.
Specify the above environment variables to switch to the PostgreSQL database.
When restoring, also specify the above environment variables to switch to the PostgreSQL database.
- Ensure that the database is accessible.
Perhaps you will use the docker-compose up -d [services name] command to start the database separately.
- Verify that the
PG_HOSTyou are using is accessible to.
If your database is running in docker-compose, you need to find the corresponding network name via docker network ls and add --network=[name] to the restore command to specify the network name.
- Restore and restart the container.