Skip to content

Instantly share code, notes, and snippets.

@samyakb
Created July 2, 2021 11:55
Show Gist options
  • Select an option

  • Save samyakb/2c10dfded3f0deade5c4bfeb7f3be905 to your computer and use it in GitHub Desktop.

Select an option

Save samyakb/2c10dfded3f0deade5c4bfeb7f3be905 to your computer and use it in GitHub Desktop.
create a user and give access to database
sudo -u postgres psql
postgres=# create database mydb;
postgres=# create user myuser with encrypted password 'mypass';
postgres=# grant all privileges on database mydb to myuser;
@samyakb
Copy link
Author

samyakb commented Jul 2, 2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment