# Latest

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

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

**Page:** 956

---

## [Using facts as variables in a task main file](https://forum.ansible.com/t/using-facts-as-variables-in-a-task-main-file/15653)

<div class="topic-metadata">

**Author:** [@Mzp45](https://forum.ansible.com/u/Mzp45)\
**Replies:** 2\
**Last updated:** [July 11, 2014, 10:06pm UTC](https://forum.ansible.com/t/using-facts-as-variables-in-a-task-main-file/15653 "2014-07-11T22:06:51Z")

</div>

Hi, I’m trying to install a package but the package manager varies across the distro. I’d like to implement something like this for e.g name: install the latest version of vmware-tools {{ ansible\_pkg\_mgr }}: name=vmw…

---

## [Search for EC2 Instances by Tag](https://forum.ansible.com/t/search-for-ec2-instances-by-tag/15603)

<div class="topic-metadata">

**Author:** [@Dan\_Chan](https://forum.ansible.com/u/Dan_Chan)\
**Replies:** 4\
**Last updated:** [July 11, 2014, 6:39pm UTC](https://forum.ansible.com/t/search-for-ec2-instances-by-tag/15603 "2014-07-11T18:39:38Z")

</div>

I have a handful of existing EC2 instances with a specific tag that I would like to target and execute Ansible against. What is the best way to go about this? I tried to use the ec2.py script for EC2 Dynamic Inventory, …

---

## [problem with ansible bastion hosts /playbook connectivity](https://forum.ansible.com/t/problem-with-ansible-bastion-hosts-playbook-connectivity/15624)

<div class="topic-metadata">

**Author:** [@Simon\_Tyler](https://forum.ansible.com/u/Simon_Tyler)\
**Replies:** 11\
**Last updated:** [July 11, 2014, 6:01pm UTC](https://forum.ansible.com/t/problem-with-ansible-bastion-hosts-playbook-connectivity/15624 "2014-07-11T18:01:51Z")

</div>

Hello, I was running an older version of ansible, and I couldn’t find a way to get it to connect through a bastion host to run scripts against a destination server, so I tried upgrading ansible. (yum upgrade to 1.6.2) N…

---

## [Initial provisioning/user setup via root remote\_user, continued CM via other remote\_user?](https://forum.ansible.com/t/initial-provisioning-user-setup-via-root-remote-user-continued-cm-via-other-remote-user/15268)

<div class="topic-metadata">

**Author:** [@Jeff\_Geerling](https://forum.ansible.com/u/Jeff_Geerling)\
**Replies:** 9\
**Last updated:** [July 10, 2014, 11:07pm UTC](https://forum.ansible.com/t/initial-provisioning-user-setup-via-root-remote-user-continued-cm-via-other-remote-user/15268 "2014-07-10T23:07:38Z")

</div>

When I order a new server from a hosting provider which doesn’t have images like AMIs or user-created Images, I generally get a minimal OS installation and a root user account. The first thing I need to do on the server…

---

## [PowmInsecureWarning: Not using mpz\_powm\_sec](https://forum.ansible.com/t/powminsecurewarning-not-using-mpz-powm-sec/13341)

<div class="topic-metadata">

**Author:** [@Bruce\_Pennypacker](https://forum.ansible.com/u/Bruce_Pennypacker)\
**Replies:** 16\
**Last updated:** [July 10, 2014, 8:40pm UTC](https://forum.ansible.com/t/powminsecurewarning-not-using-mpz-powm-sec/13341 "2014-07-10T20:40:56Z")

</div>

Ever since a recent patch to our Amazon instances we’ve been getting this warning when running Ansible: PowmInsecureWarning: Not using mpz\_powm\_sec. You should rebuild using libgmp \>= 5 to avoid timing attack vulnerabi…

---

## [How to skip local\_action if file exists?](https://forum.ansible.com/t/how-to-skip-local-action-if-file-exists/15640)

<div class="topic-metadata">

**Author:** [@Stuart\_Reynolds](https://forum.ansible.com/u/Stuart_Reynolds)\
**Replies:** 2\
**Last updated:** [July 10, 2014, 6:23pm UTC](https://forum.ansible.com/t/how-to-skip-local-action-if-file-exists/15640 "2014-07-10T18:23:15Z")

</div>

I’m trying to write a set of tasks to create an ec2 key\_pair (if one doesn’t exist) and save it to svn. Sadly, ec2\_key is quite slow for me, even if the key already exists (maybe my network?). How can I prevent this tas…

---

## [A blog post about some performance tuning options](https://forum.ansible.com/t/a-blog-post-about-some-performance-tuning-options/15646)

<div class="topic-metadata">

**Author:** [@Michael\_DeHaan1](https://forum.ansible.com/u/Michael_DeHaan1)\
**Replies:** 0\
**Last updated:** [July 10, 2014, 5:29pm UTC](https://forum.ansible.com/t/a-blog-post-about-some-performance-tuning-options/15646 "2014-07-10T17:29:38Z")

</div>

The community survey indicated some people weren’t aware of the forks parameter, so I figured this one would be a good one to write. Submitted for your approval: http://www.ansible.com/blog/ansible-performance-tuning

---

## [Dynamic inventories for Ansible Tower](https://forum.ansible.com/t/dynamic-inventories-for-ansible-tower/15645)

<div class="topic-metadata">

**Author:** [@CWS](https://forum.ansible.com/u/CWS)\
**Replies:** 1\
**Last updated:** [July 10, 2014, 4:38pm UTC](https://forum.ansible.com/t/dynamic-inventories-for-ansible-tower/15645 "2014-07-10T16:38:08Z")

</div>

Hi All, I’m trying out Ansible Tower, and I see that it can generate dynamic inventories for Rackspace and EC2. However, I don’t seem to find an option to add my own dynamic inventories. Reading the page on the latter -…

---

## [using ec2-create module output as variable](https://forum.ansible.com/t/using-ec2-create-module-output-as-variable/15562)

<div class="topic-metadata">

**Author:** [@Serkan\_C](https://forum.ansible.com/u/Serkan_C)\
**Replies:** 4\
**Last updated:** [July 10, 2014, 12:25pm UTC](https://forum.ansible.com/t/using-ec2-create-module-output-as-variable/15562 "2014-07-10T12:25:38Z")

</div>

Hi, I would like to use ec2-create module outputs as variable and pass it to other roles, this is playbook structure;

---

## [Helper library for modules written in PHP?](https://forum.ansible.com/t/helper-library-for-modules-written-in-php/15590)

<div class="topic-metadata">

**Author:** [@Andrew\_Udvare](https://forum.ansible.com/u/Andrew_Udvare)\
**Replies:** 7\
**Last updated:** [July 10, 2014, 12:23pm UTC](https://forum.ansible.com/t/helper-library-for-modules-written-in-php/15590 "2014-07-10T12:23:19Z")

</div>

Has this idea been explored? I have started writing a set of PHP classes to be located here https://github.com/Appdynamics/ansible-php. The idea is to, as part of the task, if the module is determined to be written in P…

---

## [ansible\_env.PATH, how is it set?](https://forum.ansible.com/t/ansible-env-path-how-is-it-set/15636)

<div class="topic-metadata">

**Author:** [@cjohnston](https://forum.ansible.com/u/cjohnston)\
**Replies:** 5\
**Last updated:** [July 10, 2014, 12:12pm UTC](https://forum.ansible.com/t/ansible-env-path-how-is-it-set/15636 "2014-07-10T12:12:55Z")

</div>

Hi Folks, I’m a recent adoptee of Ansible and have found it to be a very productive alternative to both Chef and Puppet. Nicely done. I’m hoping to learn a little more about the fact system and how it works; I’m running…

---

## [Issue filtering by hosts group if host in both static and dynamic inventory](https://forum.ansible.com/t/issue-filtering-by-hosts-group-if-host-in-both-static-and-dynamic-inventory/15631)

<div class="topic-metadata">

**Author:** [@Pedro\_Romano](https://forum.ansible.com/u/Pedro_Romano)\
**Replies:** 2\
**Last updated:** [July 10, 2014, 9:22am UTC](https://forum.ansible.com/t/issue-filtering-by-hosts-group-if-host-in-both-static-and-dynamic-inventory/15631 "2014-07-10T09:22:43Z")

</div>

I am having trouble filtering hosts (using the --limit switch) in the command line by specifying the static inventory hosts group that the hosts are part if said hosts are also returned by the Google Compute Engine dynam…

---

## [Ansible windows with PowerShell -ValueError: zero length field name in format](https://forum.ansible.com/t/ansible-windows-with-powershell-valueerror-zero-length-field-name-in-format/15635)

<div class="topic-metadata">

**Author:** [@L\_Venkatraman](https://forum.ansible.com/u/L_Venkatraman)\
**Replies:** 2\
**Last updated:** [July 10, 2014, 5:40am UTC](https://forum.ansible.com/t/ansible-windows-with-powershell-valueerror-zero-length-field-name-in-format/15635 "2014-07-10T05:40:40Z")

</div>

Hi I hit upon an issue using ansible to run PowerShell commands against windows nodes. I followed the instructions and got the basics working. On my linux controller node I had Python 2.6.6 and when running the simple s…

---

## [facts and callback behaviour](https://forum.ansible.com/t/facts-and-callback-behaviour/15639)

<div class="topic-metadata">

**Author:** [@lupindeterd](https://forum.ansible.com/u/lupindeterd)\
**Replies:** 2\
**Last updated:** [July 10, 2014, 1:49am UTC](https://forum.ansible.com/t/facts-and-callback-behaviour/15639 "2014-07-10T01:49:11Z")

</div>

Hi, I’m testing the callback feature and somehow they data I’m after(facts) aren’t showing up anymore after couple of run. It appears that the setup module wasn’t being called anymore. Appreciate for any pointer/hints. …

---

## [No changed plugin callback](https://forum.ansible.com/t/no-changed-plugin-callback/15634)

<div class="topic-metadata">

**Author:** [@shaol](https://forum.ansible.com/u/shaol)\
**Replies:** 5\
**Last updated:** [July 9, 2014, 10:52pm UTC](https://forum.ansible.com/t/no-changed-plugin-callback/15634 "2014-07-09T22:52:24Z")

</div>

Hi Guys I was going over the noop.py plugin callbacks on github (see https://github.com/ansible/ansible/blob/devel/lib/ansible/callback\_plugins/noop.py) and noticed there is no callback for a task’s changed status. Any …

---

## [Using pre\_tasks to install a role right before using it on a managed node?](https://forum.ansible.com/t/using-pre-tasks-to-install-a-role-right-before-using-it-on-a-managed-node/15638)

<div class="topic-metadata">

**Author:** [@Jonathan\_Rowlands](https://forum.ansible.com/u/Jonathan_Rowlands)\
**Replies:** 2\
**Last updated:** [July 9, 2014, 10:49pm UTC](https://forum.ansible.com/t/using-pre-tasks-to-install-a-role-right-before-using-it-on-a-managed-node/15638 "2014-07-09T22:49:24Z")

</div>

I don’t know if this is a normal use-case but I am using packer.io and the local ansible provisioner to build docker images. I wanted to use a pre\_task to actually install the role and then immediately use the role on a …

---

## [trying to nest loop with a hash](https://forum.ansible.com/t/trying-to-nest-loop-with-a-hash/15633)

<div class="topic-metadata">

**Author:** [@Alain\_Kreienbuhl](https://forum.ansible.com/u/Alain_Kreienbuhl)\
**Replies:** 2\
**Last updated:** [July 9, 2014, 7:54pm UTC](https://forum.ansible.com/t/trying-to-nest-loop-with-a-hash/15633 "2014-07-09T19:54:09Z")

</div>

Hello, Want I’d like to do is something like that : \` name: firewalling allow from loadbalancer ufw: rule=allow from\_ip={{item\[1\]}} proto=tcp to\_port={{item\[0\].value.porthttp}} with\_nested: my\_apps\_dict trusted\_net…

---

## [Copy module not working with sudo or su](https://forum.ansible.com/t/copy-module-not-working-with-sudo-or-su/15632)

<div class="topic-metadata">

**Author:** [@Alberto\_Losada\_Grand](https://forum.ansible.com/u/Alberto_Losada_Grand)\
**Replies:** 1\
**Last updated:** [July 9, 2014, 7:51pm UTC](https://forum.ansible.com/t/copy-module-not-working-with-sudo-or-su/15632 "2014-07-09T19:51:21Z")

</div>

Hi all, I can’t find why my code is not working when running copy with another user than root. It works fine with root and also other modules like template or yum are working fine with “no root” permissions… I tried wi…

---

## [Parameterize the HostName & HostKey in the hosts file](https://forum.ansible.com/t/parameterize-the-hostname-hostkey-in-the-hosts-file/15629)

<div class="topic-metadata">

**Author:** [@Suresh\_Katta](https://forum.ansible.com/u/Suresh_Katta)\
**Replies:** 2\
**Last updated:** [July 9, 2014, 7:50pm UTC](https://forum.ansible.com/t/parameterize-the-hostname-hostkey-in-the-hosts-file/15629 "2014-07-09T19:50:38Z")

</div>

Hi, I’m a newbie in Ansible and trying for a solution to this issue. We have a jenkins server on one machine which is connected to all the Dev, Test & Prod instances. So now on Jenkins Server, by using the Jenkins UI …

---

## [How to keep the content returned by uri from being printed in the console?](https://forum.ansible.com/t/how-to-keep-the-content-returned-by-uri-from-being-printed-in-the-console/15628)

<div class="topic-metadata">

**Author:** [@Behrang](https://forum.ansible.com/u/Behrang)\
**Replies:** 1\
**Last updated:** [July 9, 2014, 7:48pm UTC](https://forum.ansible.com/t/how-to-keep-the-content-returned-by-uri-from-being-printed-in-the-console/15628 "2014-07-09T19:48:29Z")

</div>

Hi all, Is there a way to stop Ansible from printing the content returned from a uri in the console and have return\_content=true? Thanks in advance, Behrang

---

## [Stop service before copying config file?](https://forum.ansible.com/t/stop-service-before-copying-config-file/15623)

<div class="topic-metadata">

**Author:** [@Glen\_Huang1](https://forum.ansible.com/u/Glen_Huang1)\
**Replies:** 3\
**Last updated:** [July 9, 2014, 7:36pm UTC](https://forum.ansible.com/t/stop-service-before-copying-config-file/15623 "2014-07-09T19:36:48Z")

</div>

I have a service that overwrites config when it stops. Is it possible to tell ansible that if a config file changes it should stop the service first before copying the file?

---

## [setting PATH in user crontab](https://forum.ansible.com/t/setting-path-in-user-crontab/15539)

<div class="topic-metadata">

**Author:** [@Christine\_Spang](https://forum.ansible.com/u/Christine_Spang)\
**Replies:** 3\
**Last updated:** [July 9, 2014, 9:18am UTC](https://forum.ansible.com/t/setting-path-in-user-crontab/15539 "2014-07-09T09:18:34Z")

</div>

I’m using Ansible 1.6.3 to manage a user-specific crontab. This job runs a command which, as a part of the script, calls another script located in /usr/local/bin, which is not in cron’s default PATH on Debian systems. #…

---

## [Conditional Includes, Roles and Multiple Playbooks](https://forum.ansible.com/t/conditional-includes-roles-and-multiple-playbooks/15617)

<div class="topic-metadata">

**Author:** [@Ryan\_Garrett](https://forum.ansible.com/u/Ryan_Garrett)\
**Replies:** 1\
**Last updated:** [July 8, 2014, 1:36pm UTC](https://forum.ansible.com/t/conditional-includes-roles-and-multiple-playbooks/15617 "2014-07-08T13:36:33Z")

</div>

I am trying to figure out the structure for how I am going to use Ansible and am having some design issues. I would like to have multiple playbooks in my roles, each with a subset of tasks I need to be done. E.g. - a pl…

---

## [Need advise on define inventory-specific variables](https://forum.ansible.com/t/need-advise-on-define-inventory-specific-variables/15616)

<div class="topic-metadata">

**Author:** [@Chengbing\_Liu](https://forum.ansible.com/u/Chengbing_Liu)\
**Replies:** 3\
**Last updated:** [July 8, 2014, 11:57am UTC](https://forum.ansible.com/t/need-advise-on-define-inventory-specific-variables/15616 "2014-07-08T11:57:14Z")

</div>

I’m using Ansible to deploy and maintain Hadoop clusters. I used to define variables in group\_vars/all as shown below: hadoop: Variables for core-site.xml nameservice: hadoop-namenode Variables for hdfs-site.xml dfs…

---

## [when clause in combination with list of hashes.](https://forum.ansible.com/t/when-clause-in-combination-with-list-of-hashes/15622)

<div class="topic-metadata">

**Author:** [@Nico\_K](https://forum.ansible.com/u/Nico_K)\
**Replies:** 1\
**Last updated:** [July 8, 2014, 11:55am UTC](https://forum.ansible.com/t/when-clause-in-combination-with-list-of-hashes/15622 "2014-07-08T11:55:59Z")

</div>

Hi, Consider the following list of hashes being defined: my\_list: \[ { src: “a”, dest: “b”, mode: 755 } , { src: “d”, dest: “e”, mode: 640 } \] and this task: name: example file: path: “{{ item }}” state: absent …

---

## [dict/hash-layout question](https://forum.ansible.com/t/dict-hash-layout-question/15619)

<div class="topic-metadata">

**Author:** [@stibbons.peter](https://forum.ansible.com/u/stibbons.peter)\
**Replies:** 2\
**Last updated:** [July 8, 2014, 8:34am UTC](https://forum.ansible.com/t/dict-hash-layout-question/15619 "2014-07-08T08:34:19Z")

</div>

Hi, I’m kind of new to Ansible and I haven’t really gotten the terminology down yet, so I hope you’d bear with me. I’ve got a task which loops through a bunch of disks and performs a set of operations on them. The plac…

---

## [2014 Ansible Community Survey](https://forum.ansible.com/t/2014-ansible-community-survey/15620)

<div class="topic-metadata">

**Author:** [@Michael\_DeHaan1](https://forum.ansible.com/u/Michael_DeHaan1)\
**Replies:** 0\
**Last updated:** [July 7, 2014, 8:50pm UTC](https://forum.ansible.com/t/2014-ansible-community-survey/15620 "2014-07-07T20:50:46Z")

</div>

Hi everyone, It’s time for another community survey. This one is much shorter than last time, and should probably take you 5 minutes. We’ll use the result of this to know what features everyone is using most, among oth…

---

## [Impact of merging hashes](https://forum.ansible.com/t/impact-of-merging-hashes/15618)

<div class="topic-metadata">

**Author:** [@Mehul\_Ved](https://forum.ansible.com/u/Mehul_Ved)\
**Replies:** 1\
**Last updated:** [July 7, 2014, 7:29pm UTC](https://forum.ansible.com/t/impact-of-merging-hashes/15618 "2014-07-07T19:29:53Z")

</div>

Hi, I am setting up a system using ansible where my configuration values are defined in defaults/main.yml. If the user wants to override it, they will edit vars/main.yml with the same dictionary structure. e.g. $ c…

---

## [on\_failure error handlers - any ideas](https://forum.ansible.com/t/on-failure-error-handlers-any-ideas/15614)

<div class="topic-metadata">

**Author:** [@Amr\_Ali](https://forum.ansible.com/u/Amr_Ali)\
**Replies:** 1\
**Last updated:** [July 7, 2014, 7:26pm UTC](https://forum.ansible.com/t/on-failure-error-handlers-any-ideas/15614 "2014-07-07T19:26:54Z")

</div>

Hi guys, i have been using Ansible for about a month now, my use case has been managing a client’s cluster and moving all the infrastructure management to Ansible, so far i’v been loving it… but i was working on “new se…

---

## [play\_hosts](https://forum.ansible.com/t/play-hosts/15613)

<div class="topic-metadata">

**Author:** [@sturban](https://forum.ansible.com/u/sturban)\
**Replies:** 5\
**Last updated:** [July 7, 2014, 7:24pm UTC](https://forum.ansible.com/t/play-hosts/15613 "2014-07-07T19:24:57Z")

</div>

Hi, I am a n00b and I am trying to create a CA playbook that first locally creates certs, keys etc (using easy-rsa’s pkitool) and then deploys these to the different play\_hosts. -I might be going about this the wrong wa…

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

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