Re: [ansible-project] Cannot decrypt on ubuntu

2019-08-01 Thread Barry Kaplan
I was running `file` just to show the they were ascii. But thanks, because I *thought* the files where the same. Indeed I was sure. But of course they are not. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group

Re: [ansible-project] How does Ansible deals with the remote prompt?

2019-08-01 Thread Kenneth Wong
I am confused how Ansible Expect Module will work in my use case. https://docs.ansible.com/ansible/latest/modules/expect_module.html Is this the Expect Module you mentioned? >From what I can gather, the Expect Module 1. Connects to remote device and immediately sends the command 2. Look for a

Re: [ansible-project] Cannot decrypt on ubuntu

2019-08-01 Thread Kai Stian Olstad
On 02.08.2019 00:41, Barry Kaplan wrote: > Both the password file and the file being decrypted are ascii > > ~/.ansible❯ file vault-password > vault-password: ASCII text > > > (ansible-2.8) ansible❯ file inventory/aws/ops/group_vars/all/vault_ops.yml >

[ansible-project] Cannot decrypt on ubuntu

2019-08-01 Thread Barry Kaplan
I am working with a project on a new ubuntu installation. On osx I can use ansible-vault correctly, but on ubuntu I always get (ansible-2.8) ansible❯ ansible-vault -v --vault-password-file=~/.ansible/ vault-password view inventory/aws/ops/group_vars/all/vault_ops.yml Using

Re: [ansible-project] shell module with multiple arguments using variables

2019-08-01 Thread Veera Mani
When running pup_stat alone, it works. Adding {{ }} around items did not help On Fri, Aug 2, 2019, 2:40 AM Kai Stian Olstad < ansible-project+l...@olstad.com> wrote: > On 01.08.2019 23:05, Veera wrote: > > Hi, > > > > I am trying to call variables to the shell module but failing .. > > > >

[ansible-project] Problems loading the playbook

2019-08-01 Thread ronny saavedra
Good night to run this playbook I get an error, I'm extracting data from a vcenter. Thanks I hope you can give me some guidelines on how to solve it. [image: captura_9.png] [image: captura_4.png] -- You received this message because you are subscribed to the Google Groups "Ansible

[ansible-project] Receiving facts at localhost using delegate_to is failing

2019-08-01 Thread Gabriel Rios
I have managed in the same playbook to generate certain facts and also to go over to my local pc and create the file that will receive them. What hasn't worked is the transfer of said facts. Below you can see what I'm generating in the 1st play, I'm using delegate_to & delegate_facts to send

Re: [ansible-project] shell module with multiple arguments using variables

2019-08-01 Thread Kai Stian Olstad
On 01.08.2019 23:05, Veera wrote: > Hi, > > I am trying to call variables to the shell module but failing .. > > - name: status of services >hosts: myhost >remote_user: root >gather_facts: no >vars: > - pp_stat: "/etc/init.d/puppet status" > - pr_date: "echo

Re: [ansible-project] shell module with multiple arguments using variables

2019-08-01 Thread Matt Martz
When registering a variable with a loop the structure of the data is different. Try doing a debug on just `pupstat` to see the data structure. See this documentation for more information: https://docs.ansible.com/ansible/latest/user_guide/playbooks_loops.html#registering-variables-with-a-loop

[ansible-project] shell module with multiple arguments using variables

2019-08-01 Thread Veera
Hi, I am trying to call variables to the shell module but failing .. - name: status of services hosts: myhost remote_user: root gather_facts: no vars: - pp_stat: "/etc/init.d/puppet status" - pr_date: "echo '= as on date of ==='; date" strategy: free

Re: [ansible-project] Re: Viptela Support on Ansible

2019-08-01 Thread Peter Sprygada
https://github.com/ciscodevnet/ansible-viptela On Thu, Aug 1, 2019 at 3:41 PM 'Tcpip' via Ansible Project wrote: > > Hello, > > How can I configure the playbooks to work with multi-tenant. > > THanks. > > El jueves, 26 de julio de 2018, 9:47:04 (UTC-3), Eugene Wong escribió: >> >> Hi j-16375, >>

[ansible-project] dynamic inventory

2019-08-01 Thread Sloan Miller
I am trying to get dynamic inventory working. I have not found much on the internet or in the docs that give a high level overview as to how the configs and files relate. Any tips? Can I get some suggestions on my dynamic inventory config? Is there a simple way to test and determine

Re: [ansible-project] Odd case where I cannot figure out how to eliminate {{ }} in a when: clause

2019-08-01 Thread Kai Stian Olstad
On 01.08.2019 21:58, Brian Coca wrote: > my issue with 'vars' is that it is not templated for all values, it > was never meant for direct use and we don't even use internally > anymore and we hope to remove soon. > > the `vars` lookup does template values correctly and was created for > that

Re: [ansible-project] Odd case where I cannot figure out how to eliminate {{ }} in a when: clause

2019-08-01 Thread Brian Coca
my issue with 'vars' is that it is not templated for all values, it was never meant for direct use and we don't even use internally anymore and we hope to remove soon. the `vars` lookup does template values correctly and was created for that purpose. -- -- Brian Coca -- You received

[ansible-project] Re: Viptela Support on Ansible

2019-08-01 Thread 'Tcpip' via Ansible Project
Hello, How can I configure the playbooks to work with multi-tenant. THanks. El jueves, 26 de julio de 2018, 9:47:04 (UTC-3), Eugene Wong escribió: > > Hi j-16375, > > > We are currently doing a POC with Viptela in the lab and I've written an > Ansible Galaxy module for it. > > Do you want to

[ansible-project] task to manage repos

2019-08-01 Thread Keith Mills
I need you to add a task to manage repos in the base role. The task should perform actions to create the necessary repository entries in the host, then trigger an “update packages” type call to verify the host is running the latest packages. Repo files are currently located under

[ansible-project] Re: how to solve local_action -> unreachable?

2019-08-01 Thread Gabriel Rios
Maybe you've wondered why I don't just set everything to local. My playbook contains other tasks to pull facts from a Windows machine. That's why I have the connection configured for winrm. Then I want to retrieve those facts into a .csv file created locally, which is what is failing. Update:

Re: [ansible-project] /etc not writable

2019-08-01 Thread Yuriy Buha
No, do not have root, but I do have sudo access that allows me to chown of /etc On Friday, July 28, 2017 at 8:35:30 AM UTC-4, Fayad wrote: > > Changing ownership of /etc is not a proper way. So you have root access?? > > Fayad > > Sent from my OnePlus One > > On 22-Jul-2017 5:37 PM, "Yuriy Buha"

Re: [ansible-project] Re: Ansible as a Packer provisioner hanging?

2019-08-01 Thread Matt Martz
This is being tracked in https://github.com/ansible/ansible/issues/57542 The problem is that Ansible ssh pipelining does not work with the packer ssh proxy. To a further extent, the new python interpreter discovery in ansible 2.8 uses pipelining. You can set

Re: [ansible-project] Best way to organize your playbooks

2019-08-01 Thread Михаил Политаев
Think re-examine how i look into the roles is helped to me. Now after i reorganize my roles slightly different is helped for me: Each role have purpose of install nginx, monitoring, etc. And after that high level playbook will combine them together to get application worked. For example

Re: [ansible-project] How to use piping multiple shell commands

2019-08-01 Thread Veera
Thanks Vinoth. It worked Yes . I learnt that we can use the formatting as in python either with ' ' or " ". On Thursday, August 1, 2019 at 8:59:32 AM UTC+5:30, vinoth kumar wrote: > > > > On Thu, 1 Aug 2019 at 8:57 AM, vinoth kumar > wrote: > >> Error clearly says to use proper quotes

[ansible-project] Help for variable defination

2019-08-01 Thread Rahul Kumar
HI Ansible Gurus, I have a specific snippet of code which i defined in default/main.yaml of a role xyz. sw_yum_repositories: - name: sw description: Dangerous sw file: sw-gw baseurl: "" enabled: no gpgcheck: "{{gpgcheckall | default('yes')}}" gpgkey:

[ansible-project] Ansible with windows

2019-08-01 Thread Irfan Pasha
Hi, I have been using ansible for a while and I love it. It just makes complex things very easy. So far I have been ansible on CentOS and it has been a cake walk. Now I have to do some automation on windows and I see that the WinRM is very slow. I see that just Gathering facts itself from a

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Rahul Kumar
Thanks much Sebastien, Good inputs. I tried same playbook by making state = absent and got error as expected as below: fatal: [localhost]: FAILED! => {"changed": false, "msg": "ConflictException: 409: Client Error for url: https://:/v2.0/networks/c4e67037-e32d-4e06-b0ba-7c07f6e1ec63.json, Unable

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Sebastian Meyer
Hi Rahul, On 01.08.19 12:19, Rahul Kumar wrote: > 1. whatever resources(net,subnet,sg,router etc) are provisioned as part of > this single instance creation , lets say i want to clear all those > resources in one shot , how can i do this ? Each module (os_server, os_network ...) should only

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Rahul Kumar
Thanks Sebastien and Dick. Yes , clouds.yaml can be kept in /etc/openstack/clouds.yaml or ~/.config/openstack/clouds.yaml but not in current working directory (where playbook resides). Also we can reference the named cloud directly and no need of clouds.mycloud variables etc. I directly used like

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Sebastian Meyer
Hi Rahul, On 31.07.19 09:36, Rahul Kumar wrote: > fatal: [localhost]: FAILED! => {"changed": false, "msg": "Cloud mycloud was > not found."}. > Notice clouds.yaml and Main Playbook is in same location. from the module docs: > Auth information is driven by openstacksdk, which means that values

Re: [ansible-project] Best way to organize your playbooks

2019-08-01 Thread Andrew Feller
You might re-examine whether it is appropriate for a role and a playbook as it feels like your playbooks are too heavy. Roles ideally should be reusable logic for a given context you can apply to multiple situations. For example, you might have multiple kafka/mysql/etc clusters for different

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Dick Visser
You should actually include clouds.yaml in the main playbook. On Thu, 1 Aug 2019 at 10:26, Rahul Kumar wrote: > Thanks dick but now it is complaining clouds is undefined. > > On Thu, 1 Aug 2019 at 1:50 PM, Dick Visser wrote: > >> Actually, it's this: >> >> cloud: "{{ clouds.mycloud }}" >> >>

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Rahul Kumar
Thanks dick but now it is complaining clouds is undefined. On Thu, 1 Aug 2019 at 1:50 PM, Dick Visser wrote: > Actually, it's this: > > cloud: "{{ clouds.mycloud }}" > > On Thu, 1 Aug 2019 at 10:03, Rahul Kumar wrote: > > > > sorry to come back Dick. It is still not working from clouds.yaml >

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Dick Visser
Actually, it's this: cloud: "{{ clouds.mycloud }}" On Thu, 1 Aug 2019 at 10:03, Rahul Kumar wrote: > > sorry to come back Dick. It is still not working from clouds.yaml > "msg": "The task includes an option with an undefined variable. The error > was: 'mycloud' is undefined\n\nThe error

Re: [ansible-project] Ansible For Openstack

2019-08-01 Thread Rahul Kumar
sorry to come back Dick. It is still not working from clouds.yaml "msg": "The task includes an option with an undefined variable. The error was: 'mycloud' is undefined\n\nThe error appears to be in '/root/tas/simpledemo/Main-Playbook.yaml': line 5, column 7, but may\nbe elsewhere in the file

Re: [ansible-project] Ansible Playbook iterating through different variable files

2019-08-01 Thread Kai Stian Olstad
On 31.07.2019 16:32, Kristiyan Zdravkov wrote: Could you please advise me whether I can iterate separately to each of the variable files in the directory prod with Ansible and how to do it. You would need to include_vars on one file, do some task(s), and then include the next var and do some