[ansible-project] Re: allow_duplicates: yes doesn't work as expected

2015-07-23 Thread Daniel Wendler
I have opened an Issue on github and *jimi-c* explained it logical: Hi @MorphBonehunter , the problem is because allow_duplicates needs to be set on the base role, not in each of the intermediate roles. Move

Re: [ansible-project] delegate_to does not work for array of hosts passed in to role

2015-07-23 Thread Barry Kaplan
Perfect! I have removed the connection=local from the play and now all works as expected. I guess I don't fully understand why connection=local should be used. When I was first starting with ansible plays that I studied that did ec2 stuff used it, so I did too. -- You received this message bec

Re: [ansible-project] roles/files - remote copy configuration

2015-07-23 Thread Brian Coca
This mailing list is for ansible the OSS project, for tower related issues please go to support.ansible.com or email supp...@ansible.com -- Brian Coca -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop

[ansible-project] roles/files - remote copy configuration

2015-07-23 Thread Abhishek R.
Hi, My ansible project has a role with a shell script (say, transferTempScript.sh) in the /files subdirectory. The playbook has become:yes and a become sudo user specified. When running the playbook, I get an error stating - *transferTempScript.sh: command not found*. I tracked it down to the

[ansible-project] Re: Modules Fix Missing in 1.9.2

2015-07-23 Thread Barry Kaplan
As Brian has cautioned, modules for v2 may not work with v1. But in this case, I have copied the v2 uri module into my project to gain the use of format_body and it has worked fine. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubsc

[ansible-project] Using "do until" and "with_items" together

2015-07-23 Thread Abhishek R.
Hi, I'm trying to iterate over a list, and for each iteration, I need to perform a do-until task. The task looks something like this - - name: verify if the service is truly up script: verify_service_status.sh {{ item.processName }} register: initiation_status with_items: - "{{ s

Re: [ansible-project] Modules Fix Missing in 1.9.2

2015-07-23 Thread Brian Coca
that is scheduled to be added to version 2.0 On Thu, Jul 23, 2015 at 3:47 PM, Ethan Merrill wrote: > Hi...I need this fix in 1.9.2: > > https://github.com/zecrazytux/ansible-modules-core/commit/6b20c3890f92093373c0ed50ff8489786abc1982 > > However when I install ansible 1.9.2 via pip in ubuntu, th

[ansible-project] Modules Fix Missing in 1.9.2

2015-07-23 Thread Ethan Merrill
Hi...I need this fix in 1.9.2: https://github.com/zecrazytux/ansible-modules-core/commit/6b20c3890f92093373c0ed50ff8489786abc1982 However when I install ansible 1.9.2 via pip in ubuntu, the fix is not there. Is there something special I need to do to pick it up or install ansible differently?

Re: [ansible-project] How to check if previous shell task returns an empty string

2015-07-23 Thread Brian Coca
i think you want: result.stdout|length > 0 On Thu, Jul 23, 2015 at 3:18 PM, Dump Hole wrote: > I have two shell tasks. The first one runs a check and returns a list of > ids to be removed. The second one will remove these ids. > > The stdout of the first task looks like this: > 1 > 2 > 3 > 4

[ansible-project] How to check if previous shell task returns an empty string

2015-07-23 Thread Dump Hole
I have two shell tasks. The first one runs a check and returns a list of ids to be removed. The second one will remove these ids. The stdout of the first task looks like this: 1 2 3 4 which then gets fed into the second task to remove 1, 2, 3, 4 But if the first one cannot find ids to be remo

[ansible-project] Re: variable set to a default value in play vars unexpectedly becomes not the default value

2015-07-23 Thread Kathy Allen
bump? -- 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-project+unsubscr...@googlegroups.com. To post to this group, send email to ansible-project@goog

[ansible-project] Policies for module maintenance

2015-07-23 Thread Greg DeKoenigsberg
We've now completed a comprehensive review of every old pull request in both Core and Extras repos. Each PR should now be in one of the following states, represented by a label: * community_review -- this means that a PR needs to be reviewed by the community for potential inclusion. This is the d

Re: [ansible-project] ansible pip module and --upgrade

2015-07-23 Thread Quentin Nerden
I am running into this issue also On max OSX with ansible 1.9.2 docker-py I have upgraded both with: pip install docker-py --upgrade brew install ansible --upgrade The playbook has: - hosts: testgroup # remote_user: ubuntu tasks: - name: start container docker: name: redacted

Re: [ansible-project] AWS provisioning with empty inventory

2015-07-23 Thread Rodolfo Pilas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 El 23/7/15 a las 14:38, Scott Sturdivant escribió: > What version of ansible? This implies that it was fixed: > https://github.com/ansible/ansible/issues/9712 though possibly in > a later version than what you're executing. Thank you Scott, this

Re: [ansible-project] AWS provisioning with empty inventory

2015-07-23 Thread Scott Sturdivant
What version of ansible? This implies that it was fixed: https://github.com/ansible/ansible/issues/9712 though possibly in a later version than what you're executing. On Thu, Jul 23, 2015 at 11:13 AM Rodolfo Pilas wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA256 > > > I have problems

[ansible-project] AWS provisioning with empty inventory

2015-07-23 Thread Rodolfo Pilas
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 I have problems to provision AWS when I have not at last one instance online like this: # ./playbooks/inventory/ec2.py --list { "_meta": { "hostvars": {} } } and when I try to run ansible-playbook I receive ERROR: provided hosts list is e

Re: [ansible-project] Check Multiple Directory Exists in File Module with state as directory

2015-07-23 Thread Brian Coca
- file: path="{{item}}" state=directory with_items: On Thu, Jul 23, 2015 at 12:50 PM, dinesh kumar wrote: > Hi i am trying to verify/create multiple folder exists in remote. What i've > now is > > - file: path="{{download_location}}" state=directory > - file: path="{{applications_location}}" s

[ansible-project] Check Multiple Directory Exists in File Module with state as directory

2015-07-23 Thread dinesh kumar
Hi i am trying to verify/create multiple folder exists in remote. What i've now is - file: path="{{download_location}}" state=directory - file: path="{{applications_location}}" state=directory Is there any way to check muliple folder exists? or is this preferred mkdir -p dir1 dir2 ... ? -- Yo

Re: [ansible-project] hide variable in loop execution

2015-07-23 Thread gabor . debreczeni
That did the trick, thanks a lot! On Thursday, 23 July 2015 14:45:18 UTC+1, Brian Coca wrote: > > you can set no_log: true on the task to prevent the output and logging. > > > > -- > Brian Coca > -- You received this message because you are subscribed to the Google Groups "Ansible Project" g

[ansible-project] Re: authorized_keys not looking in role 'files' directory for files

2015-07-23 Thread Guillaume Querso
what i mean is that in your main playbook (the one which trigger the roles) you have the following: vars_files: - /path/to/your/file because my understanding of your problem is that you need to access to keys stored as jinja variables in the file right? Le jeudi 23 juillet 2015 14:32:50 UTC+1

Re: [ansible-project] hide variable in loop execution

2015-07-23 Thread Brian Coca
you can set no_log: true on the task to prevent the output and logging. -- Brian Coca -- 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-project+unsu

[ansible-project] hide variable in loop execution

2015-07-23 Thread gabor . debreczeni
Hi All, I'm running a loop for deploy multiple passwords into one config file: - name: setup virtual router passwords replace: dest=/etc/keepalived/keepalived.conf regexp='{{ item.pattern }}' replace='{{ item.password }}' with_items: - { pattern:

[ansible-project] Re: authorized_keys not looking in role 'files' directory for files

2015-07-23 Thread james . mcgivern
Sorry bit of a noob how would this solve the problem? From my understanding authorized_keys 'key' takes either a string (of the key) or a url to the key file. Wouldn't having it in vars_file just be specifying the URL in a different place? Also this means I have to specify this at the host leve

[ansible-project] Re: authorized_keys not looking in role 'files' directory for files

2015-07-23 Thread Guillaume Querso
authorized_key seems to look in ./ssh have you tried to import your file in vars_files? Le jeudi 23 juillet 2015 14:06:47 UTC+1, james.m...@infinityworks.com a écrit : > > Hi, > > I'm trying to add an ssh key to all my servers via the authorized_keys > command but it doesn't seem to look in the

[ansible-project] Re: Run Powershell script on remote

2015-07-23 Thread Dimitri Yioulos
Thank you, Jon. I really appreciate the many contributions that you make to the list! On Wednesday, July 22, 2015 at 12:55:41 PM UTC-4, Dimitri Yioulos wrote: > > Apologies for what must be a very dumb question, but how do I run a > Powershell script which is located on a remote Windows machine

[ansible-project] authorized_keys not looking in role 'files' directory for files

2015-07-23 Thread james . mcgivern
Hi, I'm trying to add an ssh key to all my servers via the authorized_keys command but it doesn't seem to look in the usual places (i.e the role directory(s)). Here's my code - name: Install SSH keys authorized_key: user=vagrant key="{{ item }}" with_file: - id_rsa.pub Enter code here.

Re: [ansible-project] Re: Remote template

2015-07-23 Thread Brian Coca
something like? template: src={{lookup('uri', 'http://remote.com/file.j2'}} On Thu, Jul 23, 2015 at 3:17 AM, vitaly bichov wrote: > Hi, > > I'm facing the same issue and wonder how you solved it? > > On Monday, September 30, 2013 at 1:29:06 PM UTC+3, Bruno Dupuis wrote: >> >> Hi, >> >> Is there

Re: [ansible-project] tags with roles

2015-07-23 Thread Brian Coca
you can write the when in the include or in 2.0 use blocks On Thu, Jul 23, 2015 at 8:13 AM, Vladimir Ondrus wrote: > this is current state: > > when you want to implement this > if(x=true) > task1 > task2 > task3 > task4 > task5 > if(y=true) > task6 > task7 > > you should write when

Re: [ansible-project] tags with roles

2015-07-23 Thread Vladimir Ondrus
this is current state: when you want to implement this if(x=true) task1 task2 task3 task4 task5 if(y=true) task6 task7 you should write when to each task: task1 when x task2 when x task3 when x task4 when x task5 when x task6 when y task7 when y but when there would be something l

[ansible-project] ansible-nsupdate - module allowing dynamic dns updates

2015-07-23 Thread Marcin Skarbek
Hi, It's highly possible that someone created such module already but if not and you are looking for a simple way to add, remove or update dns record without editing zone files ansible-nsupdate allows to use dynamic update requests using TSIG. It's crappy but works and will be improved. ;) htt

[ansible-project] Re: Remote template

2015-07-23 Thread vitaly bichov
Hi, I'm facing the same issue and wonder how you solved it? On Monday, September 30, 2013 at 1:29:06 PM UTC+3, Bruno Dupuis wrote: > > Hi, > > Is there a practical way to use a remote file as a jinja template in > template modules ? > > Let's explain my use case: > > My application code requires

Re: [ansible-project] tags with roles

2015-07-23 Thread Brian Coca
the when will be applied to each task, so they will be skipped -- Brian Coca -- 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-project+unsubscr...@g

Re: [ansible-project] tags with roles

2015-07-23 Thread Vladimir Ondrus
Hi Brain, thanks for the explanation. Here is similar problem we have: We have a download role which should download something from given location(web, maven, local). So when location is maven, I dont want to execute http steps. But when "when" statement is after include this means that all tasks

[ansible-project] List of list and variables

2015-07-23 Thread Guillaume Querso
i am not sure it is possible to do so, but i would like to have a list of list. it would look like this: my_files: path: /data/ansible/testing1/ - {name: 'test1.reg', ext: '.reg'} - {name: 'test1.lst', ext: '.lst'} - {name: 'test1.sql', ext: '.sql'} path: /data/ansible/testing2/

[ansible-project] Re: Installing IIS on Windows Server 2008 R2 Standard SP1 x64

2015-07-23 Thread J Hawkesworth
Also, what ansible version are you using and how was it installed? On Thursday, July 23, 2015 at 6:46:11 AM UTC+1, J Hawkesworth wrote: > > I have a couple of suggestions... > > First, check your server 2008 is patched as per the instructions in the > blue box here: > http://docs.ansible.com/ans

Re: [ansible-project] Re: Constructing a List.

2015-07-23 Thread Igor Homyakov
Hi Jon, That is awesome. Thank you for sharing. -- Best, Igor On Wed, Jul 22, 2015 at 8:05 PM, Jon Hadfield wrote: > Hi, > > Instead of using shell, you could use a lookup plugin that will query the > ids by name for you. > So when creating the subnets, give them a name and also store them in a