diff --git a/docs/postgres.md b/docs/postgres.md index 343e62c6..4d6766ac 100644 --- a/docs/postgres.md +++ b/docs/postgres.md @@ -1,33 +1,29 @@ # Running dcrpool with PostgreSQL -Tested with PostgreSQL 13.0. +Tested with PostgreSQL 13.0, 14.9, 15.4, and 16.0. **Note:** When running in Postgres mode, backups will not be created automatically by dcrpool. ## Setup -1. Connect to your instance of PostgreSQL using `psql` to create a new database - and a new user for dcrpool. +1. Connect to your instance of PostgreSQL using `psql` to create a new role and + a new database for dcrpool. Be sure to substitute the example password `12345` with something more secure. ```no-highlight - postgres=# CREATE DATABASE dcrpooldb; - CREATE DATABASE - postgres=# CREATE USER dcrpooluser WITH ENCRYPTED PASSWORD '12345'; + postgres=# CREATE ROLE dcrpooluser WITH LOGIN NOINHERIT PASSWORD '12345'; CREATE ROLE - postgres=# GRANT ALL PRIVILEGES ON DATABASE dcrpooldb to dcrpooluser; - GRANT + postgres=# CREATE DATABASE dcrpooldb OWNER dcrpooluser; + CREATE DATABASE ``` 1. **Developers only** - if you are modifying code and wish to run the dcrpool test suite, you will need to create an additional database. ```no-highlight - postgres=# CREATE DATABASE dcrpooltestdb; + postgres=# CREATE DATABASE dcrpooltestdb OWNER dcrpooluser; CREATE DATABASE - postgres=# GRANT ALL PRIVILEGES ON DATABASE dcrpooltestdb to dcrpooluser; - GRANT ``` 1. Add the database connection details to the dcrpool config file.