sudo -i -u postgres psql
create database <dbname>;
create user <rolename> with login password 'qwerty';
grant all privileges on database <dbname> to <rolename>;