mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-07 05:42:50 +00:00
docker_* tests: check API version (#48620)
* Check minimal API and docker-py versions for all docker_* tests. * Improve docker_swarm creation/destruction for tests. * Fail when conditions aren't met. * Don't hardcode address for advertise_addr.
This commit is contained in:
committed by
John R Barker
parent
891687284f
commit
3bb41ccb8e
@@ -1,4 +1,5 @@
|
||||
- include_tasks: test_stack.yml
|
||||
when:
|
||||
- ansible_os_family != 'RedHat' or ansible_distribution_major_version != '6'
|
||||
- ansible_distribution != 'Fedora' or ansible_distribution_major_version|int >= 26
|
||||
when: docker_api_version is version('1.25', '>=')
|
||||
|
||||
- fail: msg="Too old docker / docker-py version to run docker_stack tests!"
|
||||
when: not(docker_api_version is version('1.25', '>=')) and (ansible_distribution != 'CentOS' or ansible_distribution_major_version|int > 6)
|
||||
|
||||
Reference in New Issue
Block a user