https://github.com/pexmor/ansible
Fixed Ansible docker for github docker runner
https://github.com/pexmor/ansible
Last synced: 6 months ago
JSON representation
Fixed Ansible docker for github docker runner
- Host: GitHub
- URL: https://github.com/pexmor/ansible
- Owner: PexMor
- Created: 2018-11-06T18:44:43.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-11-15T10:35:08.000Z (over 7 years ago)
- Last Synced: 2025-05-17T14:09:26.939Z (about 1 year ago)
- Language: Dockerfile
- Size: 5.86 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Ansible docker image
Fixed Ansible docker for github docker runner
# Get or update the docker image
Apart from ansible itself (version shown by the command below) it contains also
**openstacksdk** and **pyvmomi**. Those modules enables the control of
**ESXi** and/or **Openstack** (including VMWare Integrated Openstack aka VIO).
```bash
docker pull xlinux/ansible
```
# Use the image
Elementary use or test the ansible. The command below also removes the container R/W layer after execution.
```bash
docker run -it --rm xlinux/ansible
```
Real use-case would probably look like this:
```bash
docker run -it --rm \
--name ansible \
-v $PWD:/work \
-v $HOME/.docker-ansible/etc:/etc/ansible \
-v $HOME/.docker-ansible/os:/etc/openstack \
xlinux/ansible \
ansible-playbook \
playbook.yaml
```
In this example openstack and ansible config directories are mapped into the container so the python modules are happy.
And also the working directory is set to /work thus you do not have to use path when running the ansible-playbook.
# Docker hub
You can check the image at Docker hub as [xlinux/ansible](https://hub.docker.com/r/xlinux/ansible).