Containers always run as root: image USER is ignored and there is no runAsUser
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- docker, go
- Domain
- backend, infrastructure
Research direction
The report names Container API securityContext and image layer unpacking, but no source files or tests. Start by locating container creation, runtime user and group handling, and the image layer extraction path; reproduce with an image declaring USER and the reported postgres or vault cases. Done means image USER is honored, runAsUser and runAsGroup are supported, and image layer ownership is preserved.
Written by the indexing model from the issue text.
Description
On v0.6.0 an image with USER redpanda runs as uid 0 in an actor, on both gVisor and microVM. The Container API has no runAsUser or runAsGroup.
Images whose entrypoint drops to a non-root user show more problems:
- gVisor: the official
postgresimage fails withexec: "/usr/local/bin/docker-entrypoint.sh": stat /usr/local/bin/docker-entrypoint.sh: permission deniedafterCHOWN,SETUIDandSETGIDare added tosecurityContext.capabilities. Without them it fails earlier withchown: changing ownership of '/var/lib/postgresql/data': Operation not permitted.hashicorp/vaultfails atsu-exec: vault: Permission denied. - microVM:
vault server -devfails withopen /home/vault/.vault-token.tmp: permission denied, although that directory belongs to the vault user in the image.
Request
- Honor the image
USER. - Add
securityContext.runAsUserandrunAsGroup. - Keep file ownership from image layers when they are unpacked.
- Dominant language
- Go
- Stars
- 5.9k
- Forks
- 637
- Avg merge
- 2d 1h
- Merged PRs (30d)
- 523
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from agent-substrate/substrate
-
Clean up the ko retry testsPossibly taken A pull request linked to this issue is open or already merged. Openarea/dev-infra area/reliability area/tests kind/cleanup
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
agent-substrate/substrate#3461 ·
Maintainers usually reply within 1 day
-
egress: drop the empty-provider check in providerCredentialPossibly taken @cloudonly claimed this 3 days ago. Openarea/network kind/cleanup
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
agent-substrate/substrate#3428 ·
Maintainers usually reply within 1 day
-
kubectl-ate create actor-template -f <file> fails with useless errorPossibly taken @cloudonly claimed this 4 days ago. Openarea/cli kind/bug
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
agent-substrate/substrate#3406 ·
Maintainers usually reply within 1 day
-
k8s-credential-provider manifest is missing ate-otel-config envFrom, failing OTLP metric exports to [::1]:4317 / 127.0.0.1:4317 every 60sPossibly taken @ericcurtin claimed this 5 days ago. Openarea/dev-infra area/observability area/security kind/bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
agent-substrate/substrate#3282 ·
Maintainers usually reply within 1 day
-
filecachegc.runPass suppresses eviction logs when FreedBytes < target and consecutiveShortfalls > 3Possibly taken @ericcurtin claimed this 4 days ago. Openarea/node area/observability area/storage kind/bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
agent-substrate/substrate#3281 ·
Maintainers usually reply within 1 day
All issues in agent-substrate/substrate
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
limitlessprojects/Go-Hybrid#3342 ·
Maintainers usually reply within 1 day
-
status/ready type/bug
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
buildpacks/pack#2733 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
kind/bug needs-priority needs-triage
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
konveyor/tackle2-hub#1166 · 1 comment ·
Maintainers usually reply within 4 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
router-for-me/CLIProxyAPI#7209 ·
Maintainers usually reply within 1 day