-
Notifications
You must be signed in to change notification settings - Fork 216
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
Version 3: OpenShift compatibility? #427
Comments
To answer your primary question: since v3 is a complete rewrite from v2, with a different approach (in order to solve problems that could never be solved with the v2 approach), it is bound to encounter different issues. But regarding uids, everything should work transparently here; so if it doesn't, it means OpenShift is doing something different that's not taken into account. And given the previous reports we've gotten about USER containers and (That, or there's a bug in s6-overlay-suexec, which we will quickly determine.) Running with a random UID is indeed pretty stupid (it doesn't improve the security/inconvenience ratio over a fixed nonzero UID), but not the level of stupid that would break s6-overlay. To get the results you have gotten, you need much more. You're saying there's no possibility of running anything under a different UID. Does it mean that the suid feature is disabled in the kernel? With If it is the case, you can work around that by disabling the suid bit on s6-overlay-suexec. Add to your container installation file, after unpacking all the tarballs: (I'm using the Dockerfile syntax here, convert to the OpenShift way of doing things) |
I couldn't agree more with those sentiments.. it's even more that i'm unable to reproduce the issue with Back to the issue at hand.. So i tried
which is strange, as
Is the error output maybe not complete, is it not referring to the root |
So,
The goal is to always have a working Failing that, But when the container is run with a random uid, the correct uid for So your only solution here is to tell OpenShift to always pre-mount |
ok - but it still should work as intended then, right? strange that the copy fails..? so i've checked another running pod (one with no s6-overlay); the perms are like this
So:
Comparison with v2With s6-overlay 2.* i got these startup warnings:
The funny thing is, is that
I cannot really say what changed in that process that it is not longer possible with v3 ;-/ |
s6-linux-init wants
It didn't work with v2 either, it was just more subtly broken and you didn't notice it. OpenShift should allow you to pre-mount |
@skarnet |
I may finally have a solution for this. I need to implement it, then test it. Please be even more patient than you have been. |
What is the problem
So I'm forced to use OpenShift 4 and we used
s6-overlay
quite successfully on there in versions 2.* (there would be some startup warnings also, but it worked perfectly) - but after upgrading to 3.*, we get this startup error:The container then exits, nothing can be done, the battle to provide a home to the workload is lost..
So, obviously, I searched the issues here and found issue #309 - and the OpenShift use case is not covered there..
As OpenShift is quite a successful market offering, one should not really consider this an "edge case" - especially since version 2.x worked with it. So this is kinda also a BC break and/or regression.
What is different on OpenShift?
Well, on OpenShift (which is an "enterprise" Kubernetes distribution), containers are spun up with a random UID which is a member of the
root
group. Tipically, those UIDs would be in a high range like this:These users are not in
/etc/passwd
.There is no possibility to execute anything under another UID (so no setuid possible).. I guess that's why
s6-chown
fails..What is the issue?
So my primary question is this:
v3.1.0.1
.Normal remedies
So admittedly, these OpenShift constraints are annoying to say the least...
In order to deal with them, one would normally (at build time)
chgrp root
andchmod g+rw
the relevant directories that need to be writable.. that worked on all containers I encountered so far (even picky ones like nginx)..But I had no luck just chowning
/run
to root -s6-chown
will still try to do its thing and then crash - with crashes the whole container..What can be done?
Now as I read the discussion in #309, this is quite a fundamental topic.. I'm not looking to any big changes here.. I'm just looking for a workaround or a flag or whatever to leave permissions to build time, not enforcing anything regarding
chown
s andchmod
s at runtime..Thanks
Thanks for any help/suggestions.. and thanks for this project!
The text was updated successfully, but these errors were encountered: