Fix not creating the DB correctly

This commit is contained in:
Xavier Bustamante Talavera 2018-09-16 15:29:48 +02:00
parent a650f9041f
commit 146d83af24
1 changed files with 2 additions and 2 deletions

View File

@ -2,7 +2,7 @@
# Creates a database, user, and extensions to use Devicehub
createdb $1 # Create main database
psql -d $1 -c "CREATE USER dhub WITH PASSWORD 'ereuse';" # Create user devicehub uses to access db
psql -d $1 -c "GRANT ALL PRIVILEGES ON DATABASE devicehub TO dhub;" # Give access to the db
psql -d $1 -c "CREATE USER dhub WITH PASSWORD 'ereuse';" # Create user Devicehub uses to access db
psql -d $1 -c "GRANT ALL PRIVILEGES ON DATABASE $1 TO dhub;" # Give access to the db
psql -d $1 -c "CREATE EXTENSION pgcrypto SCHEMA public;" # Enable pgcrypto
psql -d $1 -c "CREATE EXTENSION ltree SCHEMA public;" # Enable ltree