-
Notifications
You must be signed in to change notification settings - Fork 571
Comments around environment and user values #2
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
Comments around environment and user values #2
Conversation
Clarify environment more strictly, and propose changes to user to separate "id" and "name" as distinct entities.
I agree with this change. We need to be explicit about the difference between id and name. |
Brandon, is the defaulting behavior of the process ownership pid something you would like to see as well (uid of run command is the implicit default uid?)
|
@smarterclayton Not sure I follow. Can you give an example? |
If uid or name are unspecified, use the owning uid of the identified "exec" process file as the default uid. Adds one more level of indirection in order to resolve the start, but avoids defaulting to "0" in many cases. Not a huge issue to me, but it's not unusual for the exec process file owner to mean something.
|
@smarterclayton I guess it depends on if this behavior works under Windows. If not it feels like it is better to be require explicitness. |
Yes, I agree that the defaulting depends on the OS behavior. On linux, unprivileged containers are possible only using a relatively newer kernel with user namespaces enabled. Hence, in most cases the container is started as root and a default of root/0 makes sense. |
"user": "daemon", | ||
"user": { | ||
"name": "daemon", | ||
"id": 0, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be a string so it can be "optional"
@smarterclayton I'm going to close this one because we have the same discussion going on in #10 about the user uid/gid vs username. There is nothing wrong with the PR, I just want to keep the discussion in one place and your PR lost the coin flip, sorry ;) |
I'll survive :). Will split the env changes out On Jun 29, 2015, at 4:48 PM, Michael Crosby [email protected] @smarterclayton https://github.com/smarterclayton I'm going to close this There is nothing wrong with the PR, I just want to keep the discussion in — |
Clarify environment more strictly, and propose changes to user to separate "id" and "name" as distinct entities. I think it is important to separate uid and name explicitly, given that the uid can be known outside the container, but the name may only have meaning inside the container (in the case of Linux containers that have custom /etc/nsswitch.conf)
Signed-off-by: Clayton Coleman [email protected]