Skip to content
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

podman systemd clutters /run with .ctr-id files #16387

Closed
edsantiago opened this issue Nov 2, 2022 · 2 comments · Fixed by #16394
Closed

podman systemd clutters /run with .ctr-id files #16387

edsantiago opened this issue Nov 2, 2022 · 2 comments · Fixed by #16394
Labels
locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.

Comments

@edsantiago
Copy link
Member

podman systemd commands do not clean up leftover .ctr-id files:

# bats --filter basic  test/system/250-systemd.bats
[passes]

# ls -l /run
...
-rw-r--r--.  1 root   root     64 Nov  2 12:36 podman_test_HvKVwQfIFo.service.ctr-id

After multiple runs of system tests, /run is full of these files. Yes, of course these are tests, not representative, but even in the real world people will be creating and removing differently-named containers and may not want these confusing stale files left behind.

Probably a simple fix, adding to one of the ExecStop stanzas.

@vrothberg
Copy link
Member

I'll take a look. Thanks, @edsantiago !

@vrothberg
Copy link
Member

I opened #16394.

vrothberg added a commit to vrothberg/libpod that referenced this issue Nov 3, 2022
Remove the container/pod ID file along with the container/pod.  It's
primarily used in the context of systemd and are not useful nor needed
once a container/pod has ceased to exist.

Fixes: containers#16387
Signed-off-by: Valentin Rothberg <[email protected]>
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 11, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants