Skip to content
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

User namespaces support based on graph driver-driven image mapping approach #6603

Closed

Conversation

dineshs-altiscale
Copy link
Contributor

No description provided.

Docker-DCO-1.1-Signed-off-by: Dinesh Subhraveti <dineshs@altiscale.com> (github: dineshs-altiscale)
Docker-DCO-1.1-Signed-off-by: Dinesh Subhraveti <dineshs@altiscale.com> (github: dineshs-altiscale)
Docker-DCO-1.1-Signed-off-by: Dinesh Subhraveti <dineshs@altiscale.com> (github: dineshs-altiscale)
Docker-DCO-1.1-Signed-off-by: Dinesh Subhraveti <dineshs@altiscale.com> (github: dineshs-altiscale)
}

// Chown any root files to docker-root
func XlateUids(root string, inverse bool) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why isn't this just called TranslateUids? It's more readable.

@cyphar
Copy link
Contributor

cyphar commented Jun 23, 2014

Also, the Xlate... utilities should have separate functions for forward and reverse mappings (or the mappings passed in should be reversed and there should only be one function), since there is a lot of code duplication when checking if something should be reverse translated or forward translated.

@dineshs-altiscale
Copy link
Contributor Author

No need to map unmapped UIDs -- that's why they are called unmapped! ; )

Kernel automatically returns overflowuid/gid if it sees no mapping. Eg., a file with an unmapped GID automatically appears as nobody group (or whatever overflowgid is.)

@crosbymichael
Copy link
Contributor

Thanks for these PRs. We finally have the Go PRs merged to add support into libcontainer and will be working on user namespaces soon after the Go 1.4 release is out.

We will review the filesystem operations after the execution aspect is complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants