Skip to content

test(features): corporate-proxy sandboxes fail to start on rootless Podman: proxy CA relabel denied #5795

Open

Description

@matthewgrossman

Problem

On rootless Podman with SELinux enforcing, a sandbox can't be created when the gateway's proxy_ca_bundle points at a root-owned file. Podman fails to relabel the bind mount:

create sandbox failed: podman API error (500): lsetxattr(label=system_u:object_r:container_file_t:s0) /etc/openshell-test/corporate-proxy/ca.pem: operation not permitted

The Podman driver mounts proxy_ca_bundle with the z option whenever SELinux is enabled (crates/openshell-driver-podman/src/container.rs, the proxy_ca_bundle mount in the container spec). Rootless Podman runs as the gateway user, which can't change the label of a file it doesn't own.

Both corporate-proxy feature tests fail this way on fedora-podman-rootless-corporate-proxy. They pass on ubuntu-docker-rootful-corporate-proxy and fedora-podman-rootful-corporate-proxy. Failing job: https://github.com/NVIDIA/OpenShell/actions/runs/44685387876/job/136123594452

To decide

  • Whether this is a product bug: an operator-owned CA under /etc is a normal setup, so relabeling it may be the wrong choice for rootless.
  • Or whether the environment should give the gateway user a copy it owns, or pre-label the file container_file_t.

Done when

The fedora-podman-rootless-corporate-proxy row is back in .github/workflows/e2e-suites.yml and both corporate-proxy feature tests pass on it.

Found while porting the corporate-proxy tests in #5786 (#5730).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

topic:testingUnit, integration, regression, conformance, E2E tests, coverage, flakes, and test infrastructure.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions