This is a Go rewrite of the python CLI tool ansible-bender.
The ansible-bender2 configuration is read directly from the playbook.
Example:
- hosts: all
vars:
var1: value
ansible_bender:
base_image: python:3.14
working_container:
volumes:
- ./README.md:/doc/README.md
user: root
target_image:
name: ansible_bender_example
labels:
app: ansible-bender2
foo: bar
annotations:
app: ansible-bender2
foo: bar
environment:
SOME_ENV: value
entrypoint:
- /command
cmd:
- --flags
user: not-root
working_dir: /run
ports:
- "8000"
- "5000"
volumes:
- /volume1
- /volume2
...ansible-bender2 build <PLAYBOOK>Run ansible-bender2 build --help for all available flags.
The source code is primarily distributed under the terms of the MIT License. See LICENSE for details.