hedgedoc / container

HedgeDoc container image resources
https://docs.hedgedoc.org/setup/docker/
195 stars 52 forks source link

database connection error - permission denied for user hedgedoc #489

Closed scheckley closed 6 months ago

scheckley commented 6 months ago

using the docker compose instructions from the website and the example docker-compose.yml:

FATAL: password authentication failed for user "hedgedoc"

is it possible to reset (or set) the default password for the database?

Thanks for any help.

SISheogorath commented 6 months ago

Yes! Assuming your database user is called hedgedoc like in the default, the following command will prompt you to set a new password:

docker-compose exec database psql -U hedgedoc -c '\password hedgedoc'

Make sure to correct the environment variables in the docker-compose file as well.

scheckley commented 6 months ago

thanks, this was still not creating a password for some reason, but I removed the container volume and pulled everything from fresh and it solved the problem. It would be good to leave the above command up for anybody else having this issue.