Open skaegi opened 4 years ago
One thing to be wary of here: assigning a random UID is not quite enough for our various init containers / helpers. The UID needs to have an entry in /etc/passwd
with a home directory defined as well. Otherwise behaviour for things like credential initialization can break - errors will start appearing related to things like being unable to copy /tekton/creds/.docker
to /.docker
. Particularly true when the disable-home-env-override
feature flag is "true".
Hmm... ok thanks Scott. I was also thinking about this some more and we probably could do this better by changing the actual underlying USER in the image.
Yeah my team has had similar experiences with random UUID and updating /etc/passwd in other scenarios as @sbwsg notes ... I can +1 the need
But in those scenarios yes @skaegi we typically have something like a USER 1001
type directive in the image's Dockerfile.
i think I ran into this over at https://github.com/tektoncd/catalog/pull/439 as well
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale
.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close
.
/lifecycle stale
Send feedback to tektoncd/plumbing.
/remove-lifecycle stale
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale
with a justification.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close
with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen
with a justification.
/lifecycle stale
Send feedback to tektoncd/plumbing.
Bump. Has there been any progress on this? Our PSP blocks anything running as root...
Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten
with a justification.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close
with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen
with a justification.
/lifecycle rotten
Send feedback to tektoncd/plumbing.
There's been some progress here. We recently updated the git-init
image to also include a nonroot
user with UID 65532. See https://github.com/tektoncd/pipeline/issues/3712 and PR https://github.com/tektoncd/pipeline/pull/3727
Obviously all the files cloned with this nonroot user are owned by UID 65532 so it's up to the user's pipeline to enforce any ownership rules they need on the files.
We've created an issue to focus on providing a similar fix in the PullRequest image: https://github.com/tektoncd/pipeline/issues/3746
/remove-lifecycle rotten
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale
with a justification.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close
with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen
with a justification.
/lifecycle stale
Send feedback to tektoncd/plumbing.
Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten
with a justification.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close
with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen
with a justification.
/lifecycle rotten
Send feedback to tektoncd/plumbing.
@sbwsg check which tekton-provided images still need root access and document accordingly. Create issues to remove this limitation for each image.
Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale
with a justification.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close
with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen
with a justification.
/lifecycle stale
Send feedback to tektoncd/plumbing.
Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten
with a justification.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close
with a justification.
If this issue should be exempted, mark the issue as frozen with /lifecycle frozen
with a justification.
/lifecycle rotten
Send feedback to tektoncd/plumbing.
/lifecycle frozen
At the very least we should assess whether this is feasible and definitively document yes/no, rather than let it atrophy.
/assign
@tektoncd/core-maintainers isn't this fixed by now ?
Running in a restricted environment a simple example TaskRun pod fails with...
The entrypoint container (the lucky winner in this case) does not require root however we should also update the other containers Tekton injects to
runAsUser: 1001
as they likely don't need root privs.