Created
December 16, 2015 15:11
-
-
Save rcanepa/fb367368646ecc1577b2 to your computer and use it in GitHub Desktop.
Basic setup for a dev and test database on PostgreSQL
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CREATE DATABASE auth; | |
CREATE DATABASE auth_test; | |
\c auth; | |
CREATE EXTENSION citext; | |
\c auth_test; | |
CREATE EXTENSION citext; | |
CREATE ROLE auth_user LOGIN; | |
ALTER ROLE auth_user WITH PASSWORD 'password1'; | |
GRANT ALL PRIVILEGES ON DATABASE auth to auth_user; | |
GRANT ALL PRIVILEGES ON DATABASE auth_test to auth_user; | |
-- About citext; | |
-- http://www.postgresql.org/docs/9.1/static/citext.html |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment