-
Notifications
You must be signed in to change notification settings - Fork 762
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
Grab all of the containers.conf settings for namespaces #3637
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: rhatdan The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
run_linux.go
Outdated
{Name: string(specs.MountNamespace), Host: true}, | ||
{Name: string(specs.NetworkNamespace), Host: true}, | ||
{Name: string(specs.PIDNamespace), Host: true}, | ||
{Name: string(specs.NetworkNamespace), Host: cfg.PidNS() == "host"}, |
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.
Copy/paste error.
91b6ff1
to
82bb93b
Compare
{Name: string(specs.MountNamespace), Host: true}, | ||
{Name: string(specs.NetworkNamespace), Host: true}, | ||
{Name: string(specs.PIDNamespace), Host: true}, | ||
{Name: string(specs.NetworkNamespace), Host: cfg.NetNS() == "host" || cfg.NetNS() == "container"}, |
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.
Why is "container" special-cased here here, for only this one namespace?
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.
I am not sure what container even means for Buildah, but this matches one of the tests expectations.
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.
container is not defined in man pages, I think it is just a compatibility mode thing.
More test redness here for you @rhatdan |
f207212
to
f465185
Compare
@giuseppe PTAL. I am curious what is going on with the two tests I had to add --cgroupns=host. Basically these tests work differently in a private cgroupns. |
I guess that is expected:
The test above would fail when running in a new cgroupns because the container cannot see its group path, but would see just
|
This should be exercising |
Buildah is mainly building with Host Namespaces, this changes most namespaces to be private matching Podman and using containers.conf Fixes: containers#3634 Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
[ "$output" != "" ] | ||
run_buildah run --terminal=false $ctr pwd | ||
[ "$output" != "" ] | ||
for cgroupns in host container private; do |
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.
Got a mixture of tabs and spaces here and on line 428.
Got a tabs/spaces mixture in |
What type of PR is this?
What this PR does / why we need it:
How to verify it
Which issue(s) this PR fixes:
Special notes for your reviewer:
Does this PR introduce a user-facing change?