Skip to content

Docker container to test ansible in on an ubuntu 18.04 image

License

Notifications You must be signed in to change notification settings

dovry/docker_ubuntu18_ansible

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Docker Ubuntu 18.04 Ansible

Build Status

Docker Pulls

Test Ansible roles in an Ubuntu 18.04 container

How to use the container

docker run --rm -d -it \
--name ubuntu18_ansible \
-v /sys/fs/cgroup:/sys/fs/cgroup:ro \
-v /run/lock:/run/lock:ro \
-v /etc/ansible:/etc/ansible:ro \
dovry/docker_ubuntu18_ansible:latest

And then either exec into the container and start hacking away with:

docker exec -it ubuntu18_ansible /bin/bash

or execute a role directly with a command such as this:

docker exec -it ubuntu18_ansible ansible-playbook /etc/ansible/playbooks/test-role.yml

Remember to set the target host in the playbook so that it is run in the container

hosts: localhost

About

Docker container to test ansible in on an ubuntu 18.04 image

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published