-
Notifications
You must be signed in to change notification settings - Fork 632
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Should gid and uid be customizable? #96
Comments
You should be able to use |
That doesn't affect the Dockerfile, everything in there is still done with the wrong uid/guid. |
Correct, but if you are mounting a directory from the host you can control the permissions of that directory to be accessible by the |
It should be something like this: me@host$ mkdir mongo-data
# also make a configdb directory if you need one
me@host$ id -u
1000
me@host$ docker run -d -v "$PWD/mongo-data:/data/db" --user 1000 mongo
# or
$ docker run -d -v "$PWD/mongo-data:/data/db" --user "$(id -u)" mongo |
Yes, sorry for wasting you guys time, I was under the impression that |
Any reason why these aren't configurable from the host? Right now on 3.3 you get a uid of 999 for example, this is a bit annoying when you mount host folders as volumes.
The text was updated successfully, but these errors were encountered: