Hi,
Can both 'podman build' and 's2i create' be used to create builder image? Please help understanding the difference.
Thanks.
Hi
`s2i create` does not create any image, but just prepares a skeleton of script files. After updating those scripts, you use `s2i build` to package those files in the container image.
`podman build` creates the container image directly, based on a containerfile/dockerfile. But this is a free-form container image description file, so anything can be done with podman.
So, the main difference is that `s2i create`+`s2i build` creates a builder image including some s2i scripts and files, from an opinionated structure, while `podman build` creates any kind of image (builder or not) based on the instructions in the containerfile.
Summarizing, you can create any kind of image with podman, but I recommend you using `s2i` if you are creating a builder image.
Hope that helps.
Jordi Sola
Hi
`s2i create` does not create any image, but just prepares a skeleton of script files. After updating those scripts, you use `s2i build` to package those files in the container image.
`podman build` creates the container image directly, based on a containerfile/dockerfile. But this is a free-form container image description file, so anything can be done with podman.
So, the main difference is that `s2i create`+`s2i build` creates a builder image including some s2i scripts and files, from an opinionated structure, while `podman build` creates any kind of image (builder or not) based on the instructions in the containerfile.
Summarizing, you can create any kind of image with podman, but I recommend you using `s2i` if you are creating a builder image.
Hope that helps.
Jordi Sola
Thanks for the nice explanation. It greatly helped me.
Regards.
Red Hat
Learning Community
A collaborative learning environment, enabling open source skill development.