-
Notifications
You must be signed in to change notification settings - Fork 172
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
restart_process
fails with permission denied
#540
Comments
Sometimes the container root filesystem has sticky bit enabled and restart commands are ran with a different user. We can work around that by creating an intermediate folder that has "0777" permissions. Refs tilt-dev#540
Sometimes the container root filesystem has sticky bit enabled and restart commands are ran with a different user. We can work around that by creating an intermediate folder that has "0777" permissions. Refs tilt-dev#540 Signed-off-by: db <[email protected]>
Sometimes the container root filesystem has sticky bit enabled and restart commands are ran with a different user. We can work around that by creating an intermediate folder that has "0777" permissions. Refs #540 Signed-off-by: db <[email protected]>
The fix was rolled back due to the regression reported in #544, sorry |
Hey, I took a look at the issue there, not sure how to proceed.
It seems for some reason docker builder garbles the parameters for this RUN command in exec form. And that path is also not correct. We can work around missing But the |
oh ya, good call... i would probably use string manipulation, something like:
https://github.com/bazelbuild/starlark/blob/master/spec.md#string%C2%B7rfind |
Thanks, this works and it also seems like a safe solution, because |
Sometimes the container root filesystem has sticky bit enabled and restart commands are ran with a different user. We can work around that by creating an intermediate folder that has "0777" permissions. The folder name is parsed with `string.rfind` because os.path.dirname won't work on Windows. Refs tilt-dev#540 Signed-off-by: db <[email protected]>
Sometimes the container root filesystem has sticky bit enabled and restart commands are ran with a different user. We can work around that by creating an intermediate folder that has "0777" permissions. The folder name is parsed with `string.rfind` because os.path.dirname won't work on Windows. Refs tilt-dev#540 Signed-off-by: db <[email protected]>
Sometimes the container root filesystem has sticky bit enabled and restart commands are ran with a different user. We can work around that by creating an intermediate folder that has "0777" permissions. The folder name is parsed with `string.rfind` because os.path.dirname won't work on Windows. Refs #540 Signed-off-by: db <[email protected]>
unfortunately, this had to be rolled back again. a container with a sticky /tmp seems pretty rare. is there some reason why you can't solve this problem with the existing |
Sad. I think you should consider banning me from any future contributions, given the track record :)
Found the root cause for my issues, though. I use colima instead of docker desktop and in a recent update it switched the base VM to ubuntu. And there is this new kernel parameter I've now set the parameter to 0, but still, would you accept a WORKDIR-based solution that I outlined in the second PR? It doesn't require |
eh, it happens. how would a WORKDIR-based solution work? |
docker_build_with_restart
has been failing for me recently, but I've found out what's the issue - even though/tmp/.restart-proc
has permissions666
, the/tmp
folder has sticky bit enabled and the containers run withroot
user instead of1001
that's the owner of/tmp/.restart-proc
.I've found two temporary workarounds, but they won't scale:
kubectl exec
into the pod and toggle/tmp
sticky bitkubectl exec
into the pod andchown /tmp/.restart-proc
Any other ideas on how to solve this? Could the
.restart-proc
file be moved to/tmp/.restart/proc
and sticky bit toggled ontmp/.restart
folder?The text was updated successfully, but these errors were encountered: