Ansible role to install and run docker containers/services.
-
docker_containers
: Dict of docker containers to run (with container name askey
).image
: Image to run- Most parameters of the
docker_container
ansible module are supported.
-
docker_services
: Dict of docker services to run with compose (thekey
is used asproject_name
).- Most parameters of the
docker_service
ansible module are supported
- Most parameters of the
- hosts: localhost
vars:
docker_containers:
nginx:
image: nginx
ports: 80:80
docker_services:
nginx:
definition:
version: '2'
services:
web:
image: nginx
ports:
- 81:80
roles:
- pyslackers.docker
MIT