A tool which builds container images using Ansible playbooks
This is a tool which bends containers using Ansible playbooks and turns them into container images. It has a pluggable builder selection — it is up to you to pick the tool which will be used to construct your container image. Right now the only supported builder is buildah. More to come in the future. Ansible-bender (ab) relies on Ansible connection plugins for performing builds.
tl;dr Ansible is the frontend, buildah is the backend.
The concept is described in following blog posts:
You may be asking: why not ansible-container? Ansible bender is actually heavily inspired by ansible-container: the main distinction is that ansible-container covers the complete lifecycle of a containerized application while ab takes care of image builds only.
Status: ready to be used
Ansible-bender was recently moved to the ansible-community organization. \o/
- You can build your container images with buildah as a backend.
- Ansible playbook is your build recipe.
- You are able to set various image metadata via CLI or as specific Ansible vars:
- working directory
- environment variables
- default command
- exposed ports
- You can do volume mounts during build.
- Caching mechanism:
- Every task result is cached as a container image layer.
- You can turn this off with
- You can disable caching from a certain point by adding a tag
no-cacheto a task.
- You can stop creating new image layers by adding tag
stop-layeringto a task.
- If an image build fails, it's committed and named with a suffix
-[TIMESTAMP]-failed(so you can take a look inside and resolve the issue).
- The tool tries to find python interpreter inside the base image.
- You can push images you built to remote locations such as:
- a registry, a tarball, docker daemon, ...
- podman push is used to perform the push.
You can read more about this project in the documentation:
Release history Release notifications | RSS feed
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
|Filename, size||File type||Python version||Upload date||Hashes|
|Filename, size ansible_bender-0.9.0-py2.py3-none-any.whl (37.4 kB)||File type Wheel||Python version py2.py3||Upload date||Hashes View|
|Filename, size ansible-bender-0.9.0.tar.gz (6.8 MB)||File type Source||Python version None||Upload date||Hashes View|
Hashes for ansible_bender-0.9.0-py2.py3-none-any.whl