Skip to content

dovry/docker_centos7_ansible

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Docker centos 7 Ansible

Build Status

Docker Pulls

Test Ansible roles in a Centos 7 container

How to use the container

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

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

docker exec -it centos7_ansible /bin/bash

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

docker exec -it centos7_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

Test Ansible roles in a Centos 7 container

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published