diff --git a/scripts/resetdatabase.sql b/scripts/resetdatabase.sql index df251920a0..a1553f965f 100644 --- a/scripts/resetdatabase.sql +++ b/scripts/resetdatabase.sql @@ -1,3 +1,2 @@ DROP DATABASE unleash; -CREATE DATABASE unleash; -GRANT ALL PRIVILEGES ON DATABASE unleash TO unleash_user; +CREATE DATABASE unleash WITH OWNER unleash_user; diff --git a/website/docs/contributing/backend/overview.md b/website/docs/contributing/backend/overview.md index 085f525eed..d7afe61097 100644 --- a/website/docs/contributing/backend/overview.md +++ b/website/docs/contributing/backend/overview.md @@ -27,17 +27,15 @@ yarn dev To run and develop unleash, you need to have PostgreSQL database (PostgreSQL v14.x or newer) locally. -Unleash currently also work with PostgreSQL v14+, but this might change in a future feature release, and we have stopped running automatic integration tests below PostgreSQL v12. +Unleash currently also work with PostgreSQL v14+, but this might change in a future feature release, and we have stopped running automatic integration tests below PostgreSQL v12. The current recommendation is to use a role with Owner privileges since Unleash uses Postgres functions to simplify our database usage. ### Create a local unleash databases in postgres {#create-a-local-unleash-databases-in-postgres} ```bash $ psql postgres <