The good news about containers, like Docker, is that they make it easier to deploy applications, and you can run many more on a server than on a virtual machine. The bad news is that putting an application in a container can be difficult. That’s where Buildah comes in.
Buildah 1.0: Linux container construction made easy
Buildah is a newly released shell program for building efficient and fast Open Container Initiative (OCI) applications and Docker-compatible images and containers. Buildah simplifies the process of creating, building and updating images while reducing the learning curve of the container environment.
Better yet, for those interested in continuous integration (CI), it is easily programmable and can be used in an environment where one needs to automatically rotate containers based on application calls. There is no requirement for a container runtime daemon to run on your system to take resources and complicate the compilation process.
There has been a great need for this type of programme. Too often, IT professionals, who should know better, deploy applications in containers, which have been created by others, without knowing what’s inside them.
This makes as much sense as running an unknown installation program on Windows. While there are companies, such as Bitnami, that create reliable containers, all too often people take advantage of the first container application they can find that meets their needs.
With Buildah, you can now easily build your own containerized application using only the components you need and trust. Red Hat’s consulting software engineer, Daniel Walsh, explained: “They challenged my engineering team to create a ‘coreutils’ of container images; essentially, a utility that could be used with existing container host tools like cp, make, yum and more to build OCI and Docker container images. These images could be stored in container logs and used by a multitude of container run times.
Buildah was the result. Oh, and the name? Walsh wrote, “The engineers asked me what to call him, and I answered,’Just call him a builder. The engineers heard my Boston accent and Buildah was born.
Buildah provides only the basic needs needed to create or change Linux container images, making it easy to integrate them into the segmentation of existing application compilations.
Walsh added, “When we say’basic needs,’ we mean it. Buildah allows the instant creation of containers from scratch, think of it as an empty box. For example, Buildah can assemble containers that skip things like package managers (DNF / YUM), which are not required by the final image. So Buildah can not only provide the ability to build these containers in a less complex and secure way, but can reduce swelling (and therefore image size) and extend customization to what you need in your native cloud applications.
In addition, “since Buildah is not without faults, it is easier to run it in a container without setting up a special infrastructure on the host or having to “filter” the host sockets in the container. You can run Buildah within your Kubernetes (or Kubernetes companies, such as Red Hat OpenShift Cluster).
With this first version 1.0, Buildah supports external read/write volumes during compilations. This allows developers to create container images that reference external volumes while they are building, but without having to send those external volumes in the full image. This simplifies the creation of images without distending those images with unnecessary and unwanted production artefacts.
In addition, Buildah can help create images that better meet Federal Information Processing Standards (FIPS). With this, you can use Buildah to build and run containers in FIPS mode for customers who require FIPS-compatible applications.
Finally, Buildah now also offers multi-stage construction, multiple methods of container transport.
Focusing exclusively on building and manipulating container images, Buildah is a useful tool for anyone working with Linux containers. Whether you are a developer testing images locally or looking for a standalone imager for a production toolchain, Buildah is a valuable addition to your tool belt container.