# Latest

**URL:** https://forum.ansible.com/latest.md?page=887

[Latest](https://forum.ansible.com/latest.md) · [Categories](https://forum.ansible.com/categories.md) · [Tags](https://forum.ansible.com/tags.md)

**Page:** 888

---

## [format variable inside list](https://forum.ansible.com/t/format-variable-inside-list/17727)

<div class="topic-metadata">

**Author:** [@Arba\_Sasmoyo](https://forum.ansible.com/u/Arba_Sasmoyo)\
**Replies:** 0\
**Last updated:** [March 12, 2015, 9:44am UTC](https://forum.ansible.com/t/format-variable-inside-list/17727 "2015-03-12T09:44:54Z")

</div>

hi, i have a question how to format variable inside list and print them to a template. i want to install php with memcache, so i have php servers group and memcache servers group. in order to integrate them, i have to mo…

---

## [Bug in ansible 1.8.4 with regards to step?](https://forum.ansible.com/t/bug-in-ansible-1-8-4-with-regards-to-step/17726)

<div class="topic-metadata">

**Author:** [@Eric\_Van\_Steenbergen](https://forum.ansible.com/u/Eric_Van_Steenbergen)\
**Replies:** 2\
**Last updated:** [March 12, 2015, 9:24am UTC](https://forum.ansible.com/t/bug-in-ansible-1-8-4-with-regards-to-step/17726 "2015-03-12T09:24:52Z")

</div>

Hi all, I recently upgraded two of my four ansible servers to 1.8.4 and from then on the --step option no longer works. The other two servers are running 1.8.2 and have no issues at all. This is the error I’m getting wh…

---

## [Help with with\_items from file](https://forum.ansible.com/t/help-with-with-items-from-file/17723)

<div class="topic-metadata">

**Author:** [@Chanaka\_Samarajeewa](https://forum.ansible.com/u/Chanaka_Samarajeewa)\
**Replies:** 0\
**Last updated:** [March 11, 2015, 6:41pm UTC](https://forum.ansible.com/t/help-with-with-items-from-file/17723 "2015-03-11T18:41:13Z")

</div>

Hello, I am trying to use with\_items: from a file but I am getting the following error. I can’t find any documentation to help me with this. I’m hoping someone can help me. The error message and my files are as follows: …

---

## [Idea: --list-tasks show task's tags](https://forum.ansible.com/t/idea-list-tasks-show-tasks-tags/17579)

<div class="topic-metadata">

**Author:** [@Leonel\_Galan\_Recinos](https://forum.ansible.com/u/Leonel_Galan_Recinos)\
**Replies:** 2\
**Last updated:** [March 11, 2015, 6:24pm UTC](https://forum.ansible.com/t/idea-list-tasks-show-tasks-tags/17579 "2015-03-11T18:24:58Z")

</div>

Re post from ansible-project I’ve been learning Ansible in the last couple of months and when using roles from Ansible Galaxy, it’s hard to know which tags each tasks has. I’ve search and couldn’t find a way to show all…

---

## [K-root (DNS instance) uses Ansible](https://forum.ansible.com/t/k-root-dns-instance-uses-ansible/17721)

<div class="topic-metadata">

**Author:** [@Jan-Piet\_Mens](https://forum.ansible.com/u/Jan-Piet_Mens)\
**Replies:** 1\
**Last updated:** [March 11, 2015, 6:22pm UTC](https://forum.ansible.com/t/k-root-dns-instance-uses-ansible/17721 "2015-03-11T18:22:45Z")

</div>

Just a small quote regarding K-root (DNS) from the good folk at RIPE \[1\]: "Configuration management of our K-root server platforms is now automated almost entirely, using a customised tool set based on …

---

## [Crontab environment variables](https://forum.ansible.com/t/crontab-environment-variables/17722)

<div class="topic-metadata">

**Author:** [@Doug\_Luce](https://forum.ansible.com/u/Doug_Luce)\
**Replies:** 0\
**Last updated:** [March 11, 2015, 6:07pm UTC](https://forum.ansible.com/t/crontab-environment-variables/17722 "2015-03-11T18:07:26Z")

</div>

I've submitted https://github.com/ansible/ansible-modules-core/pull/923 for more complex handling of crontab environment variables. I made it a separate module from cron as I wasn't sure of the best way of unifying th…

---

## [with\_items: not working for me.](https://forum.ansible.com/t/with-items-not-working-for-me/17604)

<div class="topic-metadata">

**Author:** [@Chanaka\_Samarajeewa](https://forum.ansible.com/u/Chanaka_Samarajeewa)\
**Replies:** 2\
**Last updated:** [March 11, 2015, 6:00pm UTC](https://forum.ansible.com/t/with-items-not-working-for-me/17604 "2015-03-11T18:00:00Z")

</div>

Hello, Can someone please let me know why I am getting this error message when using with\_items? Error message my task are as follows. ERROR: Syntax Error while loading YAML script, /var/lib/awx/projects/\_11813\_\_automa…

---

## [dict merge - with\_dict expects a dict](https://forum.ansible.com/t/dict-merge-with-dict-expects-a-dict/17710)

<div class="topic-metadata">

**Author:** [@John\_McNulty](https://forum.ansible.com/u/John_McNulty)\
**Replies:** 7\
**Last updated:** [March 11, 2015, 5:22pm UTC](https://forum.ansible.com/t/dict-merge-with-dict-expects-a-dict/17710 "2015-03-11T17:22:56Z")

</div>

Hi, So here’s the scenario - I’m given a data structure that when converted to yaml looks like this (names & numbers invented). \` host\_routes: route-oob: device: bond.123 routes: 10.118.0.0/16: ‘10.118.255.254’ r…

---

## [Conditions based on dict (environmental variable)](https://forum.ansible.com/t/conditions-based-on-dict-environmental-variable/17720)

<div class="topic-metadata">

**Author:** [@Bence\_Takacs](https://forum.ansible.com/u/Bence_Takacs)\
**Replies:** 0\
**Last updated:** [March 11, 2015, 4:41pm UTC](https://forum.ansible.com/t/conditions-based-on-dict-environmental-variable/17720 "2015-03-11T16:41:51Z")

</div>

If I check a remote dict item (inside a role/playbook), that may not be present like: debug msg="JAVA\_HOME= {{ ansible\_env.JAVA\_HOME }} " Then I get the following exception: TASK: \[java-noinstall | debug msg="JAVA\_…

---

## [Ansible 1.9.0 rc1 is now available](https://forum.ansible.com/t/ansible-1-9-0-rc1-is-now-available/17714)

<div class="topic-metadata">

**Author:** [@James\_Cammarata](https://forum.ansible.com/u/James_Cammarata)\
**Replies:** 5\
**Last updated:** [March 11, 2015, 3:49pm UTC](https://forum.ansible.com/t/ansible-1-9-0-rc1-is-now-available/17714 "2015-03-11T15:49:14Z")

</div>

Hi all, we’ve just tagged the rc1 release for 1.9, which you can test as follows: To test from source, simply clone the git repository (if you haven’t already) and do the following: $ git checkout v1.9.0-0.1.rc1 $ . h…

---

## [extending a module, try/finally](https://forum.ansible.com/t/extending-a-module-try-finally/17716)

<div class="topic-metadata">

**Author:** [@Mirko\_Friedenhagen](https://forum.ansible.com/u/Mirko_Friedenhagen)\
**Replies:** 2\
**Last updated:** [March 11, 2015, 3:43pm UTC](https://forum.ansible.com/t/extending-a-module-try-finally/17716 "2015-03-11T15:43:31Z")

</div>

Hello, is there a way to invoke other modules? Basically, I want to do this: tmp = template(password\_script, mode=0700) try: synchronize(args, SUDO\_ASKPASS=tmp) finally: os.remove(tmp) Is this possible or do I hav…

---

## [Trying to git clone from private repo on GitHub](https://forum.ansible.com/t/trying-to-git-clone-from-private-repo-on-github/13826)

<div class="topic-metadata">

**Author:** [@Jay\_Pipes](https://forum.ansible.com/u/Jay_Pipes)\
**Replies:** 3\
**Last updated:** [March 11, 2015, 3:10pm UTC](https://forum.ansible.com/t/trying-to-git-clone-from-private-repo-on-github/13826 "2015-03-11T15:10:26Z")

</div>

Hello all, I’m trying to git clone a private repo from GitHub in an Ansible playbook, and the playbook is hanging trying to git clone. I’ve added the SSH key that is being used for the user running Ansible as a Deploy K…

---

## [Waiting for Elastic IP address?](https://forum.ansible.com/t/waiting-for-elastic-ip-address/15558)

<div class="topic-metadata">

**Author:** [@Jason\_Levitt](https://forum.ansible.com/u/Jason_Levitt)\
**Replies:** 5\
**Last updated:** [March 11, 2015, 4:20am UTC](https://forum.ansible.com/t/waiting-for-elastic-ip-address/15558 "2015-03-11T04:20:39Z")

</div>

Does anyone have an example of waiting for an Elastic IP address to become “ready” to access? Apparently, waiting for state=started and port 22 to become accessible (see below) is not sufficient. The next step after t…

---

## [Discover a hostname in one play and use it to run the next play?](https://forum.ansible.com/t/discover-a-hostname-in-one-play-and-use-it-to-run-the-next-play/17707)

<div class="topic-metadata">

**Author:** [@Michael\_Blakeley](https://forum.ansible.com/u/Michael_Blakeley)\
**Replies:** 4\
**Last updated:** [March 11, 2015, 2:24am UTC](https://forum.ansible.com/t/discover-a-hostname-in-one-play-and-use-it-to-run-the-next-play/17707 "2015-03-11T02:24:31Z")

</div>

I’m doing some cloud scripting that involves some work on one host, then using the results to take action on another host. The hostname of the second host is a dynamic result of that first bit, and won’t be in my invento…

---

## [How to make unarchive be quiet](https://forum.ansible.com/t/how-to-make-unarchive-be-quiet/17715)

<div class="topic-metadata">

**Author:** [@Rick\_Kasten](https://forum.ansible.com/u/Rick_Kasten)\
**Replies:** 0\
**Last updated:** [March 11, 2015, 12:19am UTC](https://forum.ansible.com/t/how-to-make-unarchive-be-quiet/17715 "2015-03-11T00:19:16Z")

</div>

We use unarchive to install some pretty massive tarballs, and the “check\_results” section of the JSON is massive, many times filling up my entire screen buffer. I don’t care what “check\_results” finds, because I already …

---

## [group name or inventory file name in tasks or jinja](https://forum.ansible.com/t/group-name-or-inventory-file-name-in-tasks-or-jinja/17702)

<div class="topic-metadata">

**Author:** [@Marc\_Patermann](https://forum.ansible.com/u/Marc_Patermann)\
**Replies:** 3\
**Last updated:** [March 10, 2015, 5:17pm UTC](https://forum.ansible.com/t/group-name-or-inventory-file-name-in-tasks-or-jinja/17702 "2015-03-10T17:17:43Z")

</div>

Hi, I have two inventories, each for test an production. And I call ansible(-playbook) explicitly with one of these, to not mix things up. :slight\_smile: (Things like IP configuration differ from test and production.) …

---

## [Conditinals based on remote facts](https://forum.ansible.com/t/conditinals-based-on-remote-facts/17708)

<div class="topic-metadata">

**Author:** [@Bence\_Takacs](https://forum.ansible.com/u/Bence_Takacs)\
**Replies:** 3\
**Last updated:** [March 10, 2015, 3:23pm UTC](https://forum.ansible.com/t/conditinals-based-on-remote-facts/17708 "2015-03-10T15:23:07Z")

</div>

Hi I would need to run tasks based on a remote fact - by executing a script to extract the actual variable. Currently I’m doing it in the following way: name: Check Java Version shell: $JAVA\_HOME/bin/java -version …

---

## [role dependencies, with variables as arguments, called from multiple roles](https://forum.ansible.com/t/role-dependencies-with-variables-as-arguments-called-from-multiple-roles/16904)

<div class="topic-metadata">

**Author:** [@Robb\_Wagoner](https://forum.ansible.com/u/Robb_Wagoner)\
**Replies:** 1\
**Last updated:** [March 10, 2015, 8:28am UTC](https://forum.ansible.com/t/role-dependencies-with-variables-as-arguments-called-from-multiple-roles/16904 "2015-03-10T08:28:00Z")

</div>

I’d like for roles which configure Node apps, to generate some snippets for an HAProxy config. I’d like to be able to call the same role dependency, app\_snippet, in a generalized way, across many apps (app1, app2, etc.).…

---

## [uploading ssl certificates to aws, for use with elb](https://forum.ansible.com/t/uploading-ssl-certificates-to-aws-for-use-with-elb/17706)

<div class="topic-metadata">

**Author:** [@Rahul\_Mehrotra](https://forum.ansible.com/u/Rahul_Mehrotra)\
**Replies:** 1\
**Last updated:** [March 9, 2015, 10:11pm UTC](https://forum.ansible.com/t/uploading-ssl-certificates-to-aws-for-use-with-elb/17706 "2015-03-09T22:11:58Z")

</div>

Hi, I was wondering if there is a way to upload ssl certificate to aws accounts to be used by elb ? I have been using aws cli in combination with ansible, however it gives an error if the certificate is already present …

---

## [How to access host vars from within a connection plugin](https://forum.ansible.com/t/how-to-access-host-vars-from-within-a-connection-plugin/17705)

<div class="topic-metadata">

**Author:** [@tim5](https://forum.ansible.com/u/tim5)\
**Replies:** 1\
**Last updated:** [March 9, 2015, 10:09pm UTC](https://forum.ansible.com/t/how-to-access-host-vars-from-within-a-connection-plugin/17705 "2015-03-09T22:09:29Z")

</div>

An arbitrary host var can be set in my hostfiles/inventory file: \[www\] myserver.blah.com ansible\_connection=MY\_NEW\_CONNECTION someVar1=abc Now… in plugins/connection\_plugins/MY\_NEW\_CONNECTION.py… how do i access some…

---

## [Where to put shared code of modules](https://forum.ansible.com/t/where-to-put-shared-code-of-modules/17704)

<div class="topic-metadata">

**Author:** [@Rene\_Moser](https://forum.ansible.com/u/Rene_Moser)\
**Replies:** 4\
**Last updated:** [March 9, 2015, 9:43pm UTC](https://forum.ansible.com/t/where-to-put-shared-code-of-modules/17704 "2015-03-09T21:43:04Z")

</div>

Hi I am developing modules for cloudstack https://github.com/resmo/ansible-cloudstack and having a bunch of modules which have some similar common code. I would like to separate this code into a separate file which can …

---

## [dumping host\_vars - how do I filter out sensitive data?](https://forum.ansible.com/t/dumping-host-vars-how-do-i-filter-out-sensitive-data/17678)

<div class="topic-metadata">

**Author:** [@Larry\_Fast](https://forum.ansible.com/u/Larry_Fast)\
**Replies:** 2\
**Last updated:** [March 9, 2015, 7:13pm UTC](https://forum.ansible.com/t/dumping-host-vars-how-do-i-filter-out-sensitive-data/17678 "2015-03-09T19:13:07Z")

</div>

I’m using the following jinja2 code to dump my hostvars for diagnostics {{ hostvars | to\_nice\_json }} I would like to pre-filter this dump to exclude sensitive data. I can manage a list of sensitive values but is there …

---

## [How to do best organization of install and delete in the same ansible playbook?](https://forum.ansible.com/t/how-to-do-best-organization-of-install-and-delete-in-the-same-ansible-playbook/17701)

<div class="topic-metadata">

**Author:** [@Valeriy\_Solovyov](https://forum.ansible.com/u/Valeriy_Solovyov)\
**Replies:** 0\
**Last updated:** [March 9, 2015, 3:01pm UTC](https://forum.ansible.com/t/how-to-do-best-organization-of-install-and-delete-in-the-same-ansible-playbook/17701 "2015-03-09T15:01:04Z")

</div>

Hello, I try to figure how I must to construct an ansible playbooks with install/delete commands where it’s variable changes. For example apt\_repository,apt,yum… where state=present → installed and state=absent → delet…

---

## [Check for the existence of data on an Ansible server before attempting distribution](https://forum.ansible.com/t/check-for-the-existence-of-data-on-an-ansible-server-before-attempting-distribution/17698)

<div class="topic-metadata">

**Author:** [@cmacrae](https://forum.ansible.com/u/cmacrae)\
**Replies:** 1\
**Last updated:** [March 9, 2015, 2:48pm UTC](https://forum.ansible.com/t/check-for-the-existence-of-data-on-an-ansible-server-before-attempting-distribution/17698 "2015-03-09T14:48:33Z")

</div>

I’ve been trying to come up with an elegant solution to this, but alas; no such luck - perhaps some of you smart people can help. Enough blabbering: I have a directory containing subdirectories named after some groups i…

---

## [Unit testing python code ?](https://forum.ansible.com/t/unit-testing-python-code/17696)

<div class="topic-metadata">

**Author:** [@Torsten\_Reinhard](https://forum.ansible.com/u/Torsten_Reinhard)\
**Replies:** 1\
**Last updated:** [March 9, 2015, 2:15pm UTC](https://forum.ansible.com/t/unit-testing-python-code/17696 "2015-03-09T14:15:03Z")

</div>

Hi, I´ve written a simple RegEx filter (filter\_plugins/filter.py) which is used by some of our playbooks: \` import re def matchattr(objList, attrib, pattern): listFiltered = for item in objList: if re.match(patte…

---

## [How to get all tasks of ansible playbook limit to ansible\_os\_family?](https://forum.ansible.com/t/how-to-get-all-tasks-of-ansible-playbook-limit-to-ansible-os-family/17699)

<div class="topic-metadata">

**Author:** [@Valeriy\_Solovyov](https://forum.ansible.com/u/Valeriy_Solovyov)\
**Replies:** 0\
**Last updated:** [March 9, 2015, 1:21pm UTC](https://forum.ansible.com/t/how-to-get-all-tasks-of-ansible-playbook-limit-to-ansible-os-family/17699 "2015-03-09T13:21:49Z")

</div>

Hello, I need get all tasks from ansible playbook and show them. My problem is that condition like ansible\_os\_family == “Debian” not executing and I see all tasks. I created class, that allow to get playbook tasks pla…

---

## [Strange behavior with accelerate mode](https://forum.ansible.com/t/strange-behavior-with-accelerate-mode/17697)

<div class="topic-metadata">

**Author:** [@Marco\_Tozzi](https://forum.ansible.com/u/Marco_Tozzi)\
**Replies:** 0\
**Last updated:** [March 9, 2015, 11:32am UTC](https://forum.ansible.com/t/strange-behavior-with-accelerate-mode/17697 "2015-03-09T11:32:02Z")

</div>

Hi, we are facing a problem using accelerate mode on a PlayBook . I particular we run the playbook from a Jenkins slave (single client) to two remote server. At the first run , all is work fine, the daemon is started …

---

## [Error on Ansible tower cli on OSX](https://forum.ansible.com/t/error-on-ansible-tower-cli-on-osx/17660)

<div class="topic-metadata">

**Author:** [@JuanJose\_Vidanez](https://forum.ansible.com/u/JuanJose_Vidanez)\
**Replies:** 1\
**Last updated:** [March 9, 2015, 10:59am UTC](https://forum.ansible.com/t/error-on-ansible-tower-cli-on-osx/17660 "2015-03-09T10:59:37Z")

</div>

Hello all, I’m trying to use the tower-cli on OSx and I’m getting the following error: ➜ ~ sudo pip install ansible-tower-cli The directory ‘/Users/jvidanez/Library/Logs/pip’ or its parent directory is not owned by th…

---

## [EC2 Inventory plugin AND](https://forum.ansible.com/t/ec2-inventory-plugin-and/17616)

<div class="topic-metadata">

**Author:** [@Daniel\_Richardson](https://forum.ansible.com/u/Daniel_Richardson)\
**Replies:** 2\
**Last updated:** [March 9, 2015, 1:53am UTC](https://forum.ansible.com/t/ec2-inventory-plugin-and/17616 "2015-03-09T01:53:31Z")

</div>

Is there any way to use AND in the instance\_filters parameter instead of OR? For instance I would like to be able to filter on tag:env=stage AND tag:Owner=me

---

## [Setting a variable just for a task](https://forum.ansible.com/t/setting-a-variable-just-for-a-task/17685)

<div class="topic-metadata">

**Author:** [@Jim\_McMahon](https://forum.ansible.com/u/Jim_McMahon)\
**Replies:** 3\
**Last updated:** [March 9, 2015, 1:46am UTC](https://forum.ansible.com/t/setting-a-variable-just-for-a-task/17685 "2015-03-09T01:46:19Z")

</div>

Is there a way to set a variable just for a task? Say the task uses the template module and I want to set a variable just for that task that is not specific to the host I’m on.

[Previous page](https://forum.ansible.com/latest.md?page=886)

[Next page](https://forum.ansible.com/latest.md?page=888)
