decred / dcrpool

decred mining pool
ISC License
29 stars 27 forks source link

docs: Update postgres guide with tested new vers. #384

Closed davecgh closed 1 year ago

davecgh commented 1 year ago

This updates the postgres guide to include the latest versions of postgres which I've now tested and confirmed that they work as intended.

It also modifies the instructions to create a role with login and then create a database with that role as owner as opposed to creating a user that is then granted persmissions to the database.

This approach is generally preferred and all recent versions of postgres (versions >= 8.1) treat 'create user' as an alias for 'create role' with the login permission granted anyway.

As an aside, historically roles were allowed to own database objects while users were not, however, since users are actually just roles nowadays, there is no long a distinction. However, it is still widely considered best practice to use 'create role' when the role will be the owner of a databaes for backward compatibility.