Created
June 16, 2013 19:41
-
-
Save ronanguilloux/5793147 to your computer and use it in GitHub Desktop.
Elcaro tutorial tip: Postgtresql new user & db creation
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
$ sudo apt-get install postgresql | |
$ sudo -i -u postgres | |
$ psql | |
CREATE USER elcaro; | |
ALTER ROLE elcaro WITH CREATEDB; | |
CREATE DATABASE "ElCaro" OWNER elcaro; | |
ALTER USER elcaro WITH ENCRYPTED PASSWORD 'elcaro'; | |
\q | |
$ postgres@computer:~$ exit | |
$ cd /path/to/elcaro | |
$ psql -U elcaro -d ElCaro -f sql/structure.sql |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment