jwetzell/docker-guacamole

postgres uid causing container to be unusable

simonaplin opened this issue · 3 comments

Describe The Bug:
When launching the container the postgres uid is set to 103. On my system 103 is already mapped to tss which makes the postgres folder unreachable by postgres inside the container.

To Reproduce:
Launch the container on a system where 103 is mapped to tss

Expected behavior:
I would really like it if there was an environment variable to specify a uid for the postgres user created in the startup script to prevent local conflicts like this.

Logs:
guacamole_guacamole.1.q85oee0mwiqv@shammel | Starting postgres...
guacamole_guacamole.1.q85oee0mwiqv@shammel | postgres: could not access directory "/config/postgres": Permission denied
guacamole_guacamole.1.q85oee0mwiqv@shammel | /var/run/postgresql:5432 - no response
guacamole_guacamole.1.q85oee0mwiqv@shammel | Waiting for postgres to come up...
guacamole_guacamole.1.q85oee0mwiqv@shammel | Starting postgres...
guacamole_guacamole.1.q85oee0mwiqv@shammel | postgres: could not access directory "/config/postgres": Permission denied
guacamole_guacamole.1.q85oee0mwiqv@shammel | /var/run/postgresql:5432 - no response
guacamole_guacamole.1.q85oee0mwiqv@shammel | Waiting for postgres to come up...
guacamole_guacamole.1.q85oee0mwiqv@shammel | Starting postgres...
guacamole_guacamole.1.q85oee0mwiqv@shammel | postgres: could not access directory "/config/postgres": Permission denied
guacamole_guacamole.1.q85oee0mwiqv@shammel | /var/run/postgresql:5432 - no response
guacamole_guacamole.1.q85oee0mwiqv@shammel | Waiting for postgres to come up...
guacamole_guacamole.1.q85oee0mwiqv@shammel | Starting postgres...
guacamole_guacamole.1.q85oee0mwiqv@shammel | postgres: could not access directory "/config/postgres": Permission denied
guacamole_guacamole.1.q85oee0mwiqv@shammel | /var/run/postgresql:5432 - no response
guacamole_guacamole.1.q85oee0mwiqv@shammel | Waiting for postgres to come up...
guacamole_guacamole.1.q85oee0mwiqv@shammel | Starting postgres...
guacamole_guacamole.1.q85oee0mwiqv@shammel | postgres: could not access directory "/config/postgres": Permission denied
guacamole_guacamole.1.q85oee0mwiqv@shammel | /var/run/postgresql:5432 - no response
guacamole_guacamole.1.q85oee0mwiqv@shammel | Waiting for postgres to come up...
guacamole_guacamole.1.q85oee0mwiqv@shammel | Starting postgres...
guacamole_guacamole.1.q85oee0mwiqv@shammel | postgres: could not access directory "/config/postgres": Permission denied

Screenshots:
N/A

Environment:

  • Guacamole Version: latest docker version
  • Operating System: Ubuntu / Docker

Right now there is no startup script that creates the postgres user it is done during image creation. It shouldn't be too hard to add, I will look into what the proper way to do this in an image is.

Any manual workaround? I'm getting same problem with Fedora / Podman environment.

I haven't had the time to look into this. As far as I can tell in the 1.5.4 tags the UID of the postgres user is 1000.