uri module fails while httplib2 is installed

482 views
Skip to first unread message

Lars Vonk

unread,
Nov 9, 2013, 10:32:10 AM11/9/13
to ansible...@googlegroups.com
Hi,

I am trying to download some resource from the web using the uri module as follows

- name: Download the resource from the web
  uri: url={{app_url}} dest=/opt/app creates=/opt/app/{{app_version}}

This keeps failing with the following error: 

failed: [192.168.111.222] => {"failed": true, "item": ""}
msg: httplib2 is not installed

httplib2 is installed however:

lars (master)$ pip install httplib2
Requirement already satisfied (use --upgrade to upgrade): httplib2 in /usr/local/lib/python2.7/site-packages
Cleaning up...

Any idea what can be the cause?

Thanks, Lars

Lars Vonk

unread,
Nov 10, 2013, 8:40:48 AM11/10/13
to ansible...@googlegroups.com
Never mind... the task is run on the server and not on my laptop... doh!

Lars

Toby Wintermute

unread,
Aug 28, 2014, 9:43:52 PM8/28/14
to ansible...@googlegroups.com
I just spent half an hour trying to work out why this was failing too.
It'd be good if the uri module made it clearer about where the fetch was run from, I think.

Michael DeHaan

unread,
Aug 29, 2014, 8:05:00 AM8/29/14
to ansible...@googlegroups.com
Yeah, this is not something Ansible's going to do, because it's an intrinsitic language feature:

- hosts: webservers
  tasks:
     - ...

Will ALWAYS run on those servers, and that's true of all the base modules.

Unless you have a step in the middle that says local_action, etc, it's going to run where you tell it :)






--
You received this message because you are subscribed to the Google Groups "Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/d0eaa3c0-862f-45d5-985b-6aa56d41a56a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages