-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Inconsistencies when mounting /run #18531
Comments
Nice detective work, interested in opening a PR to fix. I think in all cases, with the possible exception of --read-only we should mount /run/.containerenv (If /run is on the read-only share, then we should not mount on it unless /run/.containerenv exists.) if /run is a tmpfs we should always mount it. |
|
I took a quick look and found a fix, #18535 |
Err... I thought the most reasonable thing would be to provide |
I don't think we should create content on a volume that is mounted at /run. Never have in the past, so I would see this as a breaking change. Potentially you could have the source volume be read-only also. |
You already did in the past, see the opening comment. And I dont talk about arbitrary volume mounts, but a If you follow your own logic, you must not create content on That's a ton of special cases, vs things just working the same (aslong as technically feasible). To be more exact: "systemd mode mount" , I see it functionally just as doing a |
Fixes: containers#18531 Signed-off-by: Daniel J Walsh <[email protected]>
Issue Description
There are some slight variations whether a user mounts a tmpfs in
/run
, the documentation is vague or incorrect. So this bug more or less should the problem but cant tell whether this is working as intended - then the documentation should be more explicit.There are a few switches which mount stuff in
/run
(--init
,--secret
). It should be able to reduce side-effects and documentation if things just work as expected (ie. functionality is not affected whether/run
is a tmpfs or not).It should be possible to run mounts in the correct order, or atleast detect and report if previous stuff gets undone by a mount.
Some additional guidance in the docs would be welcome, I would prefer
/run
to always be a tmpfs. It seems to make sense to hide this in a private tmpfs that is not backed by a blockdevice.Steps to reproduce the issue
Steps to reproduce the issue
podman run --rm debian ls -la /run
Describe the results you received
Inconsistencies whether
/run/.containerenv
is mounted, inconsistencies with the docs as--init
still works.podman run --rm debian ls -la /run
/run/.containerenv
is mountedpodman run --rm --tmpfs=/run debian ls -la /run
/run/.containerenv
is not mountedpodman run --rm --tmpfs=/run --init debian ls -la /run
/run/.containerenv
is not mounted,/run/podman-init
existspodman run --rm --systemd=always debian ls -la /run
/run/.containerenv
is mountedpodman run --rm --read-only debian ls -la /run
/run/.containerenv
is not mountedDescribe the results you expected
Everything working the same, no matter which way you end up with a tmpfs on
/run
.Everything working the same, no matter whether you mount tmpfs on
/run
(as long as technically possible of course).The documentation reflecting this
podman info output
Podman in a container
No
Privileged Or Rootless
Rootless
Upstream Latest Release
No
Additional environment details
Additional environment details
Additional information
Additional information like issue happens only occasionally or issue happens with a particular architecture or on a particular setting
The text was updated successfully, but these errors were encountered: