# OSX (?) ansible docker module issue

**URL:** <https://forum.ansible.com/t/osx-ansible-docker-module-issue/15530>\
**Category:** Ansible Project\
**Created:** [June 23, 2014, 9:10pm UTC](https://forum.ansible.com/t/osx-ansible-docker-module-issue/15530 "2014-06-23T21:10:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Laurent\_PETIT](https://avatars.discourse-cdn.com/v4/letter/l/8c91f0/32.png) [@Laurent\_PETIT](https://forum.ansible.com/u/Laurent_PETIT)\
**Post date:** [June 23, 2014, 9:10pm UTC](https://forum.ansible.com/t/osx-ansible-docker-module-issue/15530/1 "2014-06-23T21:10:39Z")

</div>

Hello,

On my OSX box, I’m unable to call the docker command from the docker module.

I tried to install docker both from homebrew, and then deinstall and install from pip.

Both times, I get this error:

failed: [docker2] =\> (item={‘subdomain’: ‘xxx’, ‘http’: 39003, ‘https’: 39005, ‘docker\_image’: '[docker-registry.xxx.com/my-img’](http://docker-registry.xxx.com/my-img')}) =\> {“failed”: true, “item”: {“docker\_image”: “[docker-registry.xxx.com/my-img](http://docker-registry.xxx.com/my-img)”, “http”: 39003, “https”: 39005, “subdomain”: “xxx”}, “parsed”: false}  
invalid output was: Traceback (most recent call last):  
File “/home/my-user/.ansible/tmp/ansible-tmp-1403557661.52-85899692189810/docker”, line 312, in   
from docker.client import APIError as DockerAPIError  
ImportError: No module named docker.client

Do you have any idea what is wrong with that?

Ansible version on my server maybe ?

---

<div class="post-metadata">

**Author:** ![Paul\_Durivage](https://avatars.discourse-cdn.com/v4/letter/p/94ad74/32.png) [@Paul\_Durivage](https://forum.ansible.com/u/Paul_Durivage)\
**Post date:** [June 23, 2014, 9:21pm UTC](https://forum.ansible.com/t/osx-ansible-docker-module-issue/15530/2 "2014-06-23T21:21:02Z")

</div>

Hi Laurent,

The Docker module requires the Docker python client. Run:

pip install docker-py

---

<div class="post-metadata">

**Author:** ![Laurent\_PETIT](https://avatars.discourse-cdn.com/v4/letter/l/8c91f0/32.png) [@Laurent\_PETIT](https://forum.ansible.com/u/Laurent_PETIT)\
**Post date:** [June 23, 2014, 9:26pm UTC](https://forum.ansible.com/t/osx-ansible-docker-module-issue/15530/3 "2014-06-23T21:26:44Z")

</div>

Oh indeed, (blush)

I added a pip step to my docker hosts setup.yml playbook,

Thanks !
