mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 12:50:22 -07: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:
parent
891687284f
commit
3bb41ccb8e
20 changed files with 537 additions and 481 deletions
|
@ -48,5 +48,7 @@
|
|||
- "'hello-world:latest' in result.images[0].RepoTags"
|
||||
- "'alpine:3.8' in result.images[1].RepoTags"
|
||||
|
||||
# Skip for CentOS 6
|
||||
when: ansible_distribution != 'CentOS' or ansible_distribution_major_version|int > 6
|
||||
when: docker_py_version is version('1.8.0', '>=') and docker_api_version is version('1.20', '>=')
|
||||
|
||||
- fail: msg="Too old docker / docker-py version to run docker_image_facts tests!"
|
||||
when: not(docker_py_version is version('1.8.0', '>=') and docker_api_version is version('1.20', '>=')) and (ansible_distribution != 'CentOS' or ansible_distribution_major_version|int > 6)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue