|
1 month ago | |
---|---|---|
defaults | 1 month ago | |
tasks | 1 month ago | |
README.md | 11 months ago |
This is a simple ansible role for setting up docker on a CentOS7 host. It supports the firewalld hack for docker as well.
docker_admin_users:
# These users will be added to the 'docker' group.
- username: root
docker_yum_dependencies:
# These will be installed via yum
- python-setuptools
- python-pip
- docker-compose
docker_pip_dependencies:
# These will be installed via pip (using the default python interpreter on your system)
- docker
docker_firewalld: true # This enables the firewalld hack - set to false if not using firewalld.
You can pass docker compose files or definitions via two different vars:
docker_composes
name
: required, string, project name.definition
: required, dict, docker-compose definitionrecreate
: optional, [“always”, “never”, “smart”], recreate images when restarting - smart does so only if definition has changed, default smartpull
: optional, boolean, always pull images before restarting the application, default falsebuild
: optional, boolean, forces a build of the docker image, default falsedocker_compose_files
path
: required, string, path to docker-compose projectname
and definition