# Ansible Project

**URL:** https://forum.ansible.com/c/archives/ansible-project/30.md?page=215

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

**Page:** 216

---

## [How to set timeout value for a task using shell module?](https://forum.ansible.com/t/how-to-set-timeout-value-for-a-task-using-shell-module/29337)

<div class="topic-metadata">

**Author:** [@Saravanan](https://forum.ansible.com/u/Saravanan)\
**Replies:** 3\
**Last updated:** [December 29, 2018, 8:35pm UTC](https://forum.ansible.com/t/how-to-set-timeout-value-for-a-task-using-shell-module/29337 "2018-12-29T20:35:56Z")

</div>

Hi Ansible Experts, We are running tasks using shell module. Sometime these tasks are pending due to backend application server slow response. Is there anyway to set timeout for these tasks to exit after certain time pe…

---

## [vyos\_config bug](https://forum.ansible.com/t/vyos-config-bug/29335)

<div class="topic-metadata">

**Author:** [@Anurag\_Bhatia](https://forum.ansible.com/u/Anurag_Bhatia)\
**Replies:** 1\
**Last updated:** [December 27, 2018, 8:24pm UTC](https://forum.ansible.com/t/vyos-config-bug/29335 "2018-12-27T20:24:18Z")

</div>

Hi I am trying to configure DHCP using vyos\_config in VyOS 1.2.0-rc11 Following DHCP config based on vyos wiki - https://wiki.vyos.net/wiki/DHCP\_server Part of my playbook has: name: Setup DNS server for eth3 - LAN …

---

## [Custom Credential Injection](https://forum.ansible.com/t/custom-credential-injection/29333)

<div class="topic-metadata">

**Author:** [@jbister](https://forum.ansible.com/u/jbister)\
**Replies:** 0\
**Last updated:** [December 26, 2018, 7:42pm UTC](https://forum.ansible.com/t/custom-credential-injection/29333 "2018-12-26T19:42:39Z")

</div>

Hey guys, I posted the following link about an issue with Custom Credentials: https://www.reddit.com/r/ansible/comments/a8frsf/injector\_configuration\_with\_custom\_credentials\_to/ Trying to work around the issue, I’m un…

---

## [Error using java\_keystore module. Facing Unsupported major.minor version](https://forum.ansible.com/t/error-using-java-keystore-module-facing-unsupported-major-minor-version/29332)

<div class="topic-metadata">

**Author:** [@parango](https://forum.ansible.com/u/parango)\
**Replies:** 0\
**Last updated:** [December 26, 2018, 6:54pm UTC](https://forum.ansible.com/t/error-using-java-keystore-module-facing-unsupported-major-minor-version/29332 "2018-12-26T18:54:33Z")

</div>

Hey there, I’m currently trying to use java\_keystore module and I’m getting a Unsupported major.minor version error (from java). I believe it might be something related with the version of Java vs Requirements. From doc…

---

## [How to Deal with WinRM/PSRP CredSSP Read timed out](https://forum.ansible.com/t/how-to-deal-with-winrm-psrp-credssp-read-timed-out/29331)

<div class="topic-metadata">

**Author:** [@Justin2](https://forum.ansible.com/u/Justin2)\
**Replies:** 0\
**Last updated:** [December 26, 2018, 5:35pm UTC](https://forum.ansible.com/t/how-to-deal-with-winrm-psrp-credssp-read-timed-out/29331 "2018-12-26T17:35:13Z")

</div>

\` TASK \[roles/ansible-role-dc : Copy Schema File 2\] \*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\*\* fatal: \[10.254.64.5\]: UNREACHABLE! =\> {“changed”: false, “msg”: “credssp: HTTPSConnectionPool(host=‘10.254.64.5’, port=5986): Read timed…

---

## [How to access stdout from all hosts in a localserver](https://forum.ansible.com/t/how-to-access-stdout-from-all-hosts-in-a-localserver/29327)

<div class="topic-metadata">

**Author:** [@madhav\_manne](https://forum.ansible.com/u/madhav_manne)\
**Replies:** 1\
**Last updated:** [December 26, 2018, 10:14am UTC](https://forum.ansible.com/t/how-to-access-stdout-from-all-hosts-in-a-localserver/29327 "2018-12-26T10:14:08Z")

</div>

My playbook is as follows hosts: nodes become: yes tasks: name: Run Shell Script to get IPs with 4xx and 5xx errors script: /home/ubuntu/ips.sh args: chdir: /home/ubuntu register: ips name: shell: echo “{{ hos…

---

## [Vault : ordinal not in range](https://forum.ansible.com/t/vault-ordinal-not-in-range/29318)

<div class="topic-metadata">

**Author:** [@YvanM](https://forum.ansible.com/u/YvanM)\
**Replies:** 3\
**Last updated:** [December 26, 2018, 9:28am UTC](https://forum.ansible.com/t/vault-ordinal-not-in-range/29318 "2018-12-26T09:28:09Z")

</div>

Hi, I am using Ansible from a Debian testing host. Each time I try to use a vault file it makes Ansible crash. The content of the vault file is really simple: dyndns\_pwd: 1234 smtpd\_pwd: 1234 I am sure that it contain…

---

## [Error when precheck Kolla-ansible](https://forum.ansible.com/t/error-when-precheck-kolla-ansible/29328)

<div class="topic-metadata">

**Author:** [@M\_nh\_Nguy\_n\_Ti\_n](https://forum.ansible.com/u/M_nh_Nguy_n_Ti_n)\
**Replies:** 0\
**Last updated:** [December 26, 2018, 4:41am UTC](https://forum.ansible.com/t/error-when-precheck-kolla-ansible/29328 "2018-12-26T04:41:53Z")

</div>

Hi everyone I am facing this problem when precheck with Kolla-ansible. My IP: controller 172.16.32.16. compute-01: 172.16.32.15, compute-02:172.16.32.14 Please help me. Thank a lot! fatal: \[172.16.32.15\]: FAILED! =\> …

---

## [How to cancel pending Ansible Tower jobs dynamically](https://forum.ansible.com/t/how-to-cancel-pending-ansible-tower-jobs-dynamically/29326)

<div class="topic-metadata">

**Author:** [@Saravanan](https://forum.ansible.com/u/Saravanan)\
**Replies:** 0\
**Last updated:** [December 25, 2018, 6:44pm UTC](https://forum.ansible.com/t/how-to-cancel-pending-ansible-tower-jobs-dynamically/29326 "2018-12-25T18:44:26Z")

</div>

Hi Ansible Experts, This question is more relevant to Ansible Tower. We are running multiple Ansible Job templates with different scheduler in Ansible Tower. Sometime few jobs are pending, causes other jobs in the queu…

---

## [What are the correct sFTP settings for Ansible](https://forum.ansible.com/t/what-are-the-correct-sftp-settings-for-ansible/29325)

<div class="topic-metadata">

**Author:** [@Baraka\_Baraka](https://forum.ansible.com/u/Baraka_Baraka)\
**Replies:** 0\
**Last updated:** [December 25, 2018, 5:34pm UTC](https://forum.ansible.com/t/what-are-the-correct-sftp-settings-for-ansible/29325 "2018-12-25T17:34:04Z")

</div>

Hi! I am having the problem on a DigitalOcean Ubuntu 18.04.1 LTS server, that when I ping the server with: “ansible all -m ping” I get this error message: “\[WARNING\]: sftp transfer mechanism failed on \[xxx.xxx.xxx.xxx\]”…

---

## [Help passing list from Ansible to Terraform list variable](https://forum.ansible.com/t/help-passing-list-from-ansible-to-terraform-list-variable/29320)

<div class="topic-metadata">

**Author:** [@Stephen\_Nesbitt](https://forum.ansible.com/u/Stephen_Nesbitt)\
**Replies:** 3\
**Last updated:** [December 25, 2018, 1:42am UTC](https://forum.ansible.com/t/help-passing-list-from-ansible-to-terraform-list-variable/29320 "2018-12-25T01:42:40Z")

</div>

All: I am using the terraform module and have a terraform plan that contains a list type variable. (Ansible 2.7.2) It may be my lack of deep knowledge of YAML, but every attempt I’ve tried, results in a validation erro…

---

## [\[STAT\] Execute script if it's exist](https://forum.ansible.com/t/stat-execute-script-if-its-exist/29322)

<div class="topic-metadata">

**Author:** [@mcoussi](https://forum.ansible.com/u/mcoussi)\
**Replies:** 1\
**Last updated:** [December 24, 2018, 2:13pm UTC](https://forum.ansible.com/t/stat-execute-script-if-its-exist/29322 "2018-12-24T14:13:10Z")

</div>

Hi, I want to execute a command if a file exist. The script juste create a file in the same folder. \` #/bin/sh touch test.txt \` Ansible execute module below. \`

---

## [UNREACHABLE! =\> {"changed": false, "msg": "Authentication or permission failure.](https://forum.ansible.com/t/unreachable-changed-false-msg-authentication-or-permission-failure/29313)

<div class="topic-metadata">

**Author:** [@Karol\_Oltarzewski](https://forum.ansible.com/u/Karol_Oltarzewski)\
**Replies:** 3\
**Last updated:** [December 22, 2018, 6:09am UTC](https://forum.ansible.com/t/unreachable-changed-false-msg-authentication-or-permission-failure/29313 "2018-12-22T06:09:09Z")

</div>

Good morning I have following question when I want to run Ansible-playbook by it: sudo ansible-playbook -i hosts playbook.yml -u karol -k --become -K I am getting following error: fatal: \[10.0.2.15\]: UNREACHABLE! =\> …

---

## [filtering out attributes](https://forum.ansible.com/t/filtering-out-attributes/29319)

<div class="topic-metadata">

**Author:** [@Justin\_DynamicD](https://forum.ansible.com/u/Justin_DynamicD)\
**Replies:** 1\
**Last updated:** [December 22, 2018, 4:11am UTC](https://forum.ansible.com/t/filtering-out-attributes/29319 "2018-12-22T04:11:46Z")

</div>

First I apologize if this was covered elsewhere, but nothing seemed to match my scenario… at least not in a way I could recreate. I have a role that builds a list of dictionaries. I’ve found it fairly easy to extend thi…

---

## [task with delegate\_to fails ansible\_remote\_tmp is set](https://forum.ansible.com/t/task-with-delegate-to-fails-ansible-remote-tmp-is-set/29307)

<div class="topic-metadata">

**Author:** [@asilver](https://forum.ansible.com/u/asilver)\
**Replies:** 2\
**Last updated:** [December 21, 2018, 9:43pm UTC](https://forum.ansible.com/t/task-with-delegate-to-fails-ansible-remote-tmp-is-set/29307 "2018-12-21T21:43:30Z")

</div>

Hello, I’m having a problem where a particular task is failing when I use delegate\_to. The problem is I’m also setting ansible\_remote\_tmp to a specific directory for the target systems. However, it appears that when I u…

---

## [vmware\_vm\_inventory plugin, how is it supposed to be used ?](https://forum.ansible.com/t/vmware-vm-inventory-plugin-how-is-it-supposed-to-be-used/29295)

<div class="topic-metadata">

**Author:** [@Jimmy\_Htor](https://forum.ansible.com/u/Jimmy_Htor)\
**Replies:** 2\
**Last updated:** [December 21, 2018, 4:13pm UTC](https://forum.ansible.com/t/vmware-vm-inventory-plugin-how-is-it-supposed-to-be-used/29295 "2018-12-21T16:13:48Z")

</div>

It does work, it lists the VMs (including UUID) from vCenter. So far, so good. But then? How are you supposed to obtain their DNS name or IP in order to be able to actually connect to them (i.e. use them as hosts) Thx …

---

## [Prefered way to launch a vm on vmware](https://forum.ansible.com/t/prefered-way-to-launch-a-vm-on-vmware/29314)

<div class="topic-metadata">

**Author:** [@Michael\_W](https://forum.ansible.com/u/Michael_W)\
**Replies:** 2\
**Last updated:** [December 21, 2018, 1:26pm UTC](https://forum.ansible.com/t/prefered-way-to-launch-a-vm-on-vmware/29314 "2018-12-21T13:26:59Z")

</div>

Hello, I’m new to ansible and tried to launch a Linux VM on my first Ansible tests. This means cloning a vm from a template, booting and running some first-boot commands in order to hand over controll to Puppet inside …

---

## [Remove and create directory in a single task is failing](https://forum.ansible.com/t/remove-and-create-directory-in-a-single-task-is-failing/29317)

<div class="topic-metadata">

**Author:** [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Replies:** 0\
**Last updated:** [December 21, 2018, 12:26pm UTC](https://forum.ansible.com/t/remove-and-create-directory-in-a-single-task-is-failing/29317 "2018-12-21T12:26:21Z")

</div>

You need to use with\_nested: https://docs.ansible.com/ansible/2.4/playbooks\_loops.html#nested-loops

---

## [Remove and create directory in a single task is failing](https://forum.ansible.com/t/remove-and-create-directory-in-a-single-task-is-failing/29316)

<div class="topic-metadata">

**Author:** [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Replies:** 0\
**Last updated:** [December 21, 2018, 12:16pm UTC](https://forum.ansible.com/t/remove-and-create-directory-in-a-single-task-is-failing/29316 "2018-12-21T12:16:57Z")

</div>

This is the same question as you asked in an earlier thread - to which you got two answers. Without any feedback on how that worked out for you (did you actually try them? did they work?), you are now trying almost th…

---

## ["omit" but for ordinary variables?](https://forum.ansible.com/t/omit-but-for-ordinary-variables/29309)

<div class="topic-metadata">

**Author:** [@Karl\_Auer](https://forum.ansible.com/u/Karl_Auer)\
**Replies:** 2\
**Last updated:** [December 21, 2018, 7:00am UTC](https://forum.ansible.com/t/omit-but-for-ordinary-variables/29309 "2018-12-21T07:00:03Z")

</div>

Is there anything like the “default(omit)” filter available for ordinary variable declarations? I am building a list of volume details, which will be passed too the ec2 module. With module parameters, one can comvert an…

---

## [Syntax error while running Firewall playbook](https://forum.ansible.com/t/syntax-error-while-running-firewall-playbook/29310)

<div class="topic-metadata">

**Author:** [@Prashant\_Jaiswal](https://forum.ansible.com/u/Prashant_Jaiswal)\
**Replies:** 5\
**Last updated:** [December 21, 2018, 6:59am UTC](https://forum.ansible.com/t/syntax-error-while-running-firewall-playbook/29310 "2018-12-21T06:59:25Z")

</div>

Hi, While running a playbook to enable multiple TCP & UDP ports on a remote m/c I am getting some syntax error which I can’t figure it out. The error says FAILED! =\> {“msg”: “The task includes an option with an undefine…

---

## [Converted "with\_items" play to new-style loop, now it is failing](https://forum.ansible.com/t/converted-with-items-play-to-new-style-loop-now-it-is-failing/29294)

<div class="topic-metadata">

**Author:** [@Will\_Dennis](https://forum.ansible.com/u/Will_Dennis)\
**Replies:** 5\
**Last updated:** [December 20, 2018, 4:33pm UTC](https://forum.ansible.com/t/converted-with-items-play-to-new-style-loop-now-it-is-failing/29294 "2018-12-20T16:33:13Z")

</div>

Hi all, I had a play in one of my roles that used to look like this: \` name: Ensure PRTG monitoring scripts are installed copy: src: “{{ item }}” dest: /var/prtg/scriptsxml/{{ item }} owner: root group: root mo…

---

## [Find variable in dictonary based on a known key:value pair](https://forum.ansible.com/t/find-variable-in-dictonary-based-on-a-known-key-value-pair/29306)

<div class="topic-metadata">

**Author:** [@Eric\_Brewer](https://forum.ansible.com/u/Eric_Brewer)\
**Replies:** 4\
**Last updated:** [December 20, 2018, 3:00pm UTC](https://forum.ansible.com/t/find-variable-in-dictonary-based-on-a-known-key-value-pair/29306 "2018-12-20T15:00:30Z")

</div>

So having a dictionary in a var file, how would I find a value, if I don’t know the list position, but I do know a value of another key:value pair? \` physical\_interface\_list: lan: 1 slave: no route\_list: ip4: 1.1.1…

---

## [Using a defined group\_var over an undefined host\_var (or how to hack variable precedence)](https://forum.ansible.com/t/using-a-defined-group-var-over-an-undefined-host-var-or-how-to-hack-variable-precedence/29288)

<div class="topic-metadata">

**Author:** [@Eric\_Brewer](https://forum.ansible.com/u/Eric_Brewer)\
**Replies:** 3\
**Last updated:** [December 20, 2018, 2:44pm UTC](https://forum.ansible.com/t/using-a-defined-group-var-over-an-undefined-host-var-or-how-to-hack-variable-precedence/29288 "2018-12-20T14:44:32Z")

</div>

I have a scenario where I need to be able to specify to use the group\_vars for a NTP timeserver, unless the host\_vars are defined. All of the variables are going to be coming out of an intermediary document that the cust…

---

## [Limit and selection of group with dynamic inventory](https://forum.ansible.com/t/limit-and-selection-of-group-with-dynamic-inventory/29304)

<div class="topic-metadata">

**Author:** [@Mehul\_Ved](https://forum.ansible.com/u/Mehul_Ved)\
**Replies:** 0\
**Last updated:** [December 19, 2018, 5:46pm UTC](https://forum.ansible.com/t/limit-and-selection-of-group-with-dynamic-inventory/29304 "2018-12-19T17:46:56Z")

</div>

Hello, I have a setup in google cloud which has been working very well with Ansible. Till last week, we had only one “environment” per machine. Each environment was marked by a network tag which ansible would pick up wh…

---

## [Adding rhn channels via ansible](https://forum.ansible.com/t/adding-rhn-channels-via-ansible/29303)

<div class="topic-metadata">

**Author:** [@Chris\_Bidwell](https://forum.ansible.com/u/Chris_Bidwell)\
**Replies:** 0\
**Last updated:** [December 19, 2018, 5:09pm UTC](https://forum.ansible.com/t/adding-rhn-channels-via-ansible/29303 "2018-12-19T17:09:11Z")

</div>

Hey all, How’s it going? So I’m trying to create a playbook that will add rhn-channels to servers based on both Server/Workstation. Here’s my pb:

---

## [What is the best practice to manage project \`foobar\` uninstall action ?](https://forum.ansible.com/t/what-is-the-best-practice-to-manage-project-foobar-uninstall-action/29272)

<div class="topic-metadata">

**Author:** [@Stephane\_Klein1](https://forum.ansible.com/u/Stephane_Klein1)\
**Replies:** 5\
**Last updated:** [December 19, 2018, 3:54pm UTC](https://forum.ansible.com/t/what-is-the-best-practice-to-manage-project-foobar-uninstall-action/29272 "2018-12-19T15:54:29Z")

</div>

Hi, What is the best practice to manage project foobar uninstall action ? a. Write two playbooks example: foobar\_install.yml and foobar\_uninstall.yml and two roles roles/foobar\_install\_and\_upgrade/... and roles/foobar…

---

## [Create virtual server from CSV](https://forum.ansible.com/t/create-virtual-server-from-csv/29301)

<div class="topic-metadata">

**Author:** [@Sharon\_Day](https://forum.ansible.com/u/Sharon_Day)\
**Replies:** 0\
**Last updated:** [December 19, 2018, 3:54pm UTC](https://forum.ansible.com/t/create-virtual-server-from-csv/29301 "2018-12-19T15:54:27Z")

</div>

I have a requirement to build out a virtual server by parsing the items from a CSV spreadsheet. I have it working if I’m creating a single virtual server, but if I need a virtual server using port 443 and another one usi…

---

## [Overriding AWS AMI volume device names?](https://forum.ansible.com/t/overriding-aws-ami-volume-device-names/29299)

<div class="topic-metadata">

**Author:** [@Karl\_Auer](https://forum.ansible.com/u/Karl_Auer)\
**Replies:** 0\
**Last updated:** [December 19, 2018, 1:36pm UTC](https://forum.ansible.com/t/overriding-aws-ami-volume-device-names/29299 "2018-12-19T13:36:19Z")

</div>

Hi there. I have an AMI that was taken from an instance with two EBS volumes, attached to devices /dev/sda1 and xvdb. I want to override the volume device names, and put volumes on (say) xvda and xvdf. (and xvdg, xvdh……

---

## [Accessing a sub-variable from a JSON output](https://forum.ansible.com/t/accessing-a-sub-variable-from-a-json-output/29282)

<div class="topic-metadata">

**Author:** [@JS11](https://forum.ansible.com/u/JS11)\
**Replies:** 2\
**Last updated:** [December 19, 2018, 11:39am UTC](https://forum.ansible.com/t/accessing-a-sub-variable-from-a-json-output/29282 "2018-12-19T11:39:58Z")

</div>

Hello I have a variable that contains output from a json file. \` name: set fact set\_fact: test123: “{{ jsonVar | json\_query(name\_query) }}” vars: name\_query: “.{name: name, ssh\_url\_to\_repo: ssh\_url\_to\_repo namesp…

[Previous page](https://forum.ansible.com/c/archives/ansible-project/30.md?page=214)

[Next page](https://forum.ansible.com/c/archives/ansible-project/30.md?page=216)
