-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Varios quadlet kube defaults #16597
Comments
Most of these defaults would hurt many current users of Could we solve this via CONTAINERS_CONF as discussed yesterday? I am looking at use cases where users just want to start a container systemd service at runtime without reboot. Especially when being shared on the web, git, etc. I'd expect these things to "just work" without having to, for instance, pre-fetch the images. |
Using |
Yes, we talked about that yesterday. We were thinking about adding CONTAINERS_CONF_ADDITIONAL (naming unclear) which will be loaded last. This way, all system/user settings will honored while allowing to override them where/when needed. |
I'm not sure how this would be used by quadlet. We can inject env vars easily into the podman run by setting environment keys in the service file. However, its a bit harder to generate a file somewhere to pass in as a filename, because lifetime tracking etc of the file is hard for a one-shot thing like a generator. |
Fair point. My main concern is that these defaults are too strict for most users. They totally make sense for the auto use case but less for an ordinary sysadmin. The user experience would suffer IMO - @rhatdan would probably use the goldie locks story. Could we hide these settings behind an opt-in field in the .container files? |
Yeah, i'm not 100% saying these need to be the same. Just that it may be useful to discuss them. In the "regular" quadlet Anyway, we have this one chance to set the defaults as quadlet is a new way to run apps. Once its released we have to keep those defaults forever for backwards compat. |
Understood. I think only |
I think we are mixing two different requirements here. On one hand we have default values - i.e. use when nothing else is set - and on the other, overrides - i.e. always use no matter was is set. As @rhatdan wrote in the Which one are we trying to solve here? |
@ygalblum, I am talking about default setting (i.e., the settings without user intervention). I want these to be as portable as possible such that users migrating to Quadlet have a "it just works" experience. To make services even more secure and further lock them down, we can tweak these defaults. Whether all these settings can be tweaked at the moment, I don't know. |
Lets talk about this after the thankgiving break. I love having another chance to change defaults for "containers in production", as tight as possible. But diagnosing what goes wrong might be difficult. |
We need to discuss this as the cabal meeting on Thursday. |
Let's try to come to conclusion. We've been chatting about this stuff yesterday and we also have this thread here.
These settings may make sense in a highly curated environment such as automotive. But they do not make sense for ordinary sysadmins. For such changes we should really be use-case driven or have at least some data points. A gut feeling for new defaults that haven't been tested at all in the wild is risky. As mentioned in many other threads. I think that auto should ship a special and curated containers.conf. |
I agree with @vrothberg points. |
@vrothberg Should we not have these as defaults for regular (non-kube) quadlet too then? |
Yes, I think the defaults should largely be default indepenendet of how podman is being called. User experience, test coverage, and "known to work" are my main motivators for that. |
@alexlarsson can we close the issue after #16714 is merged. |
Yeah, lets close it |
For
.container
files, quadlet uses various non-standard defaults for some things. I don't know if the same exact choices are right for .kube file, but it may be interesting to think about them.Some interesting changes that quadled containers do:
--pull=never
(i.e.ImagePullPolicy
): This is a change from the default ofIfNotPresent
. The reason I did this is that it feels rather weird to have a system service on boot start pulling down images, and I would rather just have it fail, as this feels like a sysadmin error.--readonly
(i.e.securityContext.readOnlyRootFilesystem
): This is the default for quadlet because the containers are not persistent (run with --rm), so ideally they should not use the rootfs for any storage anyway.--cap-drop=all
(securityContext.capabilities.drop
) - more secure default--security-opt=no-new-privileges
(securityContext.allowPrivilegeEscalation
) - more secure defaultSo, there are two questions. Do we want to also change these defaults for quadlet kube, and how do we pass such default changes to
podman kube play
.The text was updated successfully, but these errors were encountered: