1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Added more meaningful fail messages on Docker API

This commit is contained in:
Olaf Kilian 2015-05-07 09:36:32 +02:00 committed by Matt Clay
parent dfaa1ec528
commit a64bae30b5

View file

@ -153,6 +153,8 @@ class DockerLoginManager:
reauth=self.reauth, reauth=self.reauth,
dockercfg_path=self.dockercfg_path dockercfg_path=self.dockercfg_path
) )
except DockerAPIError as e:
self.module.fail_json(msg="Docker API Error: %s" % e.explanation)
except Exception as e: except Exception as e:
self.module.fail_json(msg="failed to login to the remote registry", error=repr(e)) self.module.fail_json(msg="failed to login to the remote registry", error=repr(e))