mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-04-26 12:21:26 -07:00
docker_* modules: unify docker module version checks (#47046)
* Unify docker module version checks. * Improve messages depending on required docker-py versions. * Linting.
This commit is contained in:
parent
4991ef30c2
commit
32e8251f86
11 changed files with 54 additions and 28 deletions
|
@ -163,7 +163,7 @@ try:
|
|||
from docker import utils
|
||||
if HAS_DOCKER_PY_2 or HAS_DOCKER_PY_3:
|
||||
from docker.types import IPAMPool, IPAMConfig
|
||||
except:
|
||||
except Exception as dummy:
|
||||
# missing docker-py handled in ansible.module_utils.docker_common
|
||||
pass
|
||||
|
||||
|
@ -384,6 +384,7 @@ def main():
|
|||
client = AnsibleDockerClient(
|
||||
argument_spec=argument_spec,
|
||||
supports_check_mode=True
|
||||
# "The docker server >= 1.9.0"
|
||||
)
|
||||
|
||||
cm = DockerNetworkManager(client)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue