I am following this tutorial to install Odoo on Ubuntu, but I get this error with command sudo -u postgres createuser -s $USER:
could not change directory to "/home/hugolvc/Documents/Code/odoo/odoo": Permission denied
How can I solve it?
I am following this tutorial to install Odoo on Ubuntu, but I get this error with command sudo -u postgres createuser -s $USER:
could not change directory to "/home/hugolvc/Documents/Code/odoo/odoo": Permission denied
How can I solve it?
The 'postgres' user doesn't have access to your current work directory, try sudo -iu postgres createuser -s $USER to run the command in a login shell as the user 'postgres' and the message should not appear, since the working directory will then be postgres's home directory.
Afterwards check with sudo -iu postgres psql -c 'SELECT * FROM pg_user' whether the creation of the user was successful.