Migrating from docker to podman and caching problem #18185
-
Hey all! I'd like to migrate from docker to podman to build images. In some pipelines we use
We use Unfortunately if I just replace docker to podman it won't work because podman (buildah) uses another caching mechanism - containers/buildah#4118, so the first building with podman rebuild all the layers (and it obviously will update package's versions), because there's no cache in the repo. Does anyone know how I can migrate from docker to podman without rebuilding all the layers? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Hi @gilgameshfreedom , podman and buildah's distributed cache is by design like this, it works with intermediate images not with an existing pre-built image. It pushesh all intermediate images to remote repo and uses the required layers during the build from remote repo. Therefore rebuilding and populating the upstream repo with all intermediate images is the only way for now. TLDR: Docker's inbuilt distributed cache cannot be used with podman/buildah as now since it uses different internal design and mechanism. Thanks |
Beta Was this translation helpful? Give feedback.
Hi @gilgameshfreedom , podman and buildah's distributed cache is by design like this, it works with intermediate images not with an existing pre-built image. It pushesh all intermediate images to remote repo and uses the required layers during the build from remote repo. Therefore rebuilding and populating the upstream repo with all intermediate images is the only way for now.
TLDR: Docker's inbuilt distributed cache cannot be used with podman/buildah as now since it uses different internal design and mechanism.
Thanks