2019-02-26 20:18:30 +01:00
---
# Run the tests
- block :
- include_tasks : run-test.yml
with_fileglob :
- "tests/*.yml"
always :
2019-02-27 20:54:32 +01:00
- name : Cleanup (trying)
docker_swarm :
state : absent
force : true
diff : no
ignore_errors : yes
- name : Restart docker daemon
service :
name : docker
state : restarted
become : yes
- name : Wait for docker daemon to be fully restarted
command : docker ps
2019-02-26 20:18:30 +01:00
- name : Cleanup
docker_swarm :
state : absent
force : true
diff : no
2019-03-04 12:10:09 +01:00
when : docker_py_version is version('1.10.0', '>=') and docker_api_version is version('1.25', '>=')
2018-11-19 11:01:40 +01:00
- fail : msg="Too old docker / docker-py version to run docker_swarm tests!"
2019-03-04 12:10:09 +01:00
when : not(docker_py_version is version('1.10.0', '>=') and docker_api_version is version('1.25', '>=')) and (ansible_distribution != 'CentOS' or ansible_distribution_major_version|int > 6)