Open edsantiago opened 4 months ago
Yeah the builds happen in parallel as the image does not yet exists. But then a tag can only pint to one image so the last build image gets the name and then latter in the code will be used as it passes around the final name not the image id.
As of how to fix I really hate the pause image. I really wanted to just use a overlay mount on the rootfs for catatonit instead os this "useless" extra image no user really cares about and that gets rebuild for each podman version
As of how to fix I really hate the pause image. I really wanted to just use a overlay mount on the rootfs for catatonit instead os this "useless" extra image no user really cares about and that gets rebuild for each podman version
i.e see last comments on the PR https://github.com/containers/podman/pull/11956#issuecomment-952770024
There were issues with that back then but maybe it is worth to try that approach again?
I did a quick experiment: https://github.com/containers/podman/commit/16f67febbcf1bad710acb5f579ed5852f4866227
This does work (of course needs proper code cleanup). However I am unsure if this is the right way to go about it. There are several things to consider: If the host binary moves or is removed the infra is permanently broken. The current copy catatonit into the pause image seems to work better in that regard as it is a full copy.
A friendly reminder that this issue had no activity for 30 days.
Initial setup:
Create three kube files, and run three kubes in parallel:
(Apparently) all three tried to build a pause image, one got tagged, the other two did not:
One of those images is in use by one of the containers, and can't be deleted until the pod stops. The other is not in use and can be rmi'ed. This confuses me because
buildPauseImage()
returns an image name, not ID. But I'm not going to lose sleep over that.Relevant code seems to be https://github.com/containers/podman/blob/main/pkg/specgen/generate/pause_image.go . I can't think of any way to fix this that doesn't involve locks, yuk. Hope y'all have better solutions.