GRANT ALL PRIVILEGES ON DATABASE yourdbname TO youruser;
$ sudo -u postgres createuser <username>
sudo -u postgres createuser -e <name>
$ sudo -u postgres createdb <dbname>
psql=# grant all privileges on database <dbname> to <username>
$ sudo -u postgres psqlpsql=# alter user <username> with encrypted password '<password>';