-
Notifications
You must be signed in to change notification settings - Fork 65
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
chown init-container should not render without secret #178
Comments
Alright, we can no longer wait. I will fork the chart and come back with a PR if we ever make it work 🤣 |
@unique-dominik do you already have something that I could take over to finish? |
Hi @eliobischof Yes I do, but its a workaround for now since I just disable the container if its not used 😢
|
This doesn't look unreasonable to me 🙂 I think just not rendering the init container makes sense if it's not needed. I'll have a look at the PR, thanks 🙏 |
👍 |
…ing user) This relies on the fact that an emptyDir is set up with appropriate permissions for whichever userid is running in the pod. The prior solution required running chown/chmod by root in the init container. This obviates the need for root, which is not permitted in many kubernetes installs as a security precaution. Fixes zitadel#177 and also fixes zitadel#178 (since there is no chown anymore).
Insecurity warning
Caution
This would only apply to insecure setups as every secure setup should at least have some secret somewhere…
Problem
When investigating #177 I discovered, that even if it is not needed for logical reasons, the
chown
container always runs.zitadel-charts/charts/zitadel/templates/deployment.yaml
Line 158 in bcfdd4f
That means, even when no secret is present to be
chown
-ed, the container still tries to change its ownership (of the, I assume, empty volume).It bothers me aesthetically but in our prototyping, which we did for #177 it basically blocked us. We have to currently delete the init conatiner after every deployment.
Proposals
Fix #177 to reduce impact
Fix #177 and the problem is not so grave anymore
Render only if secrets present
Render the container only into the chart if secrets are present, maybe like so:
and then omit the whole container if
false
.The text was updated successfully, but these errors were encountered: