Sign inSign up

pamplemousse/ansible

By pamplemousse

•Updated almost 7 years ago

The Ansible IT automation tools in a container.

Image
0

478

pamplemousse/ansible repository overview

⁠docker-ansible

Image to make the Ansible tools available in a container.

⁠Warning: this is not a standalone image !

I wanted to be able to run several version of Ansible without having to maintain too many images. Therefore, when you run this image, you need to mount the ansible code⁠ as a volume. See the usage section⁠ for examples.

⁠usage

# get the ansible code
# checkout the branch you want to use
git clone git://github.com/ansible/ansible.git --recursive ~/tools/ansible
git checkout devel
git submodule update --init --recursive

ansible_path="${HOME}/tools/ansible"

# ansible
docker run \
  --name ansible \
  --rm \
  --volume ${ansible_path}:/ansible \
  pamplemousse/ansible \
  ansible

# ansible-playbook
# run from your project folder to mount it as a volume
docker run \
  --name ansible-playbook \
  -it --rm \
  --volume ${ansible_path}:/ansible \
  --volume $(pwd):/home/ansible/project \
  -w /home/ansible/project \
  pamplemousse/ansible \
  ansible-playbook

# ansible-galaxy
# run from your project folder to mount it as a volume
docker run \
  --name ansible-galaxy \
  --rm \
  --volume ${ansible_path}:/ansible \
  --volume $(pwd):/home/ansible/project
  -w /home/ansible/project \
  pamplemousse/ansible \
  ansible-galaxy

Tag summary

Content type

Image

Digest

Size

74.6 MB

Last updated

almost 7 years ago

docker pull pamplemousse/ansible