Re: [ansible-project] Re: ansible gem not installing dependencies

2015-07-29 Thread Kyle Tarplee
I'm having the same issue with beanstalkd_view gem: name=beanstalkd_view user_install=no include_dependencies=yes state=present will not install dependencies of beanstalkd_view. Ubuntu 14.04LTS and the ansible 1.9.2 On Thursday, October 30, 2014 at 11:55:48 AM UTC-6, Michael DeHaan wrote: For

Re: [ansible-project] Re: azure required for this module error

2015-07-29 Thread Martin
Hi, You are looking at the ansible module. Usually those modules also need a python library. /Martin On Wed 29 Jul 2015 at 18:17 rsimbirt...@architech.ca wrote: I checked and it looks like it is installed /Library/Python/2.7/site-packages/ansible/modules/core/cloud/azure drwxr-xr-x 6 root

Re: [ansible-project] Re: tree/hierarchic structure for inventory?

2015-07-29 Thread esco real
Hello Martin, you are right. Supporting a tree structure for this with plain files/directories (group_vars..) wouldn't be that nice. And it is very sensible at the moment. But I made this work for me by resolving the group_vars in the tree directly to host_vars. So group names don't have to

[ansible-project] Re: azure required for this module error

2015-07-29 Thread J Hawkesworth
Looks like to use that module, you need to install a python library called 'azure'. Looking here http://docs.ansible.com/ansible/azure_module.html, it seems to need to be a version later than 0.7.1 This is probably something you can install using pip / yum / apt-get. Hope this helps. Jon On

Re: [ansible-project] PEP8 compliance in codebase

2015-07-29 Thread Brian Coca
I agree on all points. -- 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...@googlegroups.com. To post to this group,

[ansible-project] Re: azure required for this module error

2015-07-29 Thread rsimbirtsev
I checked and it looks like it is installed /Library/Python/2.7/site-packages/ansible/modules/core/cloud/azure drwxr-xr-x 6 root wheel204 16 Jul 11:29 . drwxr-xr-x 13 root wheel442 16 Jul 11:29 .. -rw-r--r-- 1 root wheel 0 16 Jul 11:28 __init__.py -rw-r--r-- 1 root wheel

Re: [ansible-project] Re: ansible gem not installing dependencies

2015-07-29 Thread Kyle Tarplee
I just figured it out. The existence of /root/.gems that met the dependencies of beanstalkd_view is what caused the issue. Gem thought the dependencies were met eventhough they were not when it was installing system wide in /var/lib/gems. I think the default for user_install should be false

Re: [ansible-project] Re: jsonfile fact caching error: error, fact_caching_connection is not set, cannot use fact cache

2015-07-29 Thread Brian Coca
have you tried setting fact_caching_connection? On Wed, Jul 29, 2015 at 3:28 PM, senorsmile senorsm...@gmail.com wrote: I should add that both machines are using ansible 1.9.2. On Wednesday, July 29, 2015 at 12:27:46 PM UTC-7, senorsmile wrote: I have added the following to ansible.cfg

[ansible-project] Rolling deploys to groups of servers

2015-07-29 Thread Guy Matz
Hello! I have the requirement to perform rolling deploys to groups of servers at a time, e.g. the first set of servers - app1_server_1, app2_server_1, app3_server1 - first, then the second set - app1_server2, app2_server2, app3_server2 - then the third set, app1_server3, app2_server3,

Re: [ansible-project] Re: How to debug very simple hanging playbook

2015-07-29 Thread Olivier Lauret
Hi All, I have tested the latest version and I have the same behaviour. So, so far , only works in 1.6.10. I guess, this is a regression. Regards, Olivier On Tuesday, 28 July 2015 16:52:23 UTC+1, Olivier Lauret wrote: Hello Brian, Thank you for your answer. I have tried that and it is

[ansible-project] Pause with prompt in loop - not prompting - 1.9.2

2015-07-29 Thread Craig Moynes
Hi, Just getting started with Ansible (1.9.2) and trying to get a playbook configured to deploy the latest version of our developers code. What I wanted to do was loop through the property files from the source, and if there was a difference (by md5 comparison) prompt the user that they

[ansible-project] How do I configure Ansible to run kickstart for RHEL VM's

2015-07-29 Thread Gerald Pruchniewski
I found this link which provides a lot of great information https://groups.google.com/forum/#!topic/pysphere/iTNRGbtbans on what I'm trying to accomplish.The first problem I have is it looks like it wants the vCenter username and password to be in plain text. I was wondering if there is

Re: [ansible-project] Re: How to manage authorized_keys?

2015-07-29 Thread Mischa ter Smitten
Have a look at our ssh-keys role. https://github.com/Oefenweb/ansible-ssh-keys -- 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] Ansible not pulling in group_vars

2015-07-29 Thread datsun80
I moved my inventory files to their own directory and now the group_vars are not loading. Ansible Docs state: Tip: In Ansible 1.2 or later the group_vars/ and host_vars/ directories can exist in either the playbook directory OR the inventory directory. If both paths exist, variables in the

[ansible-project] Re: Does the file module handle wildcards?

2015-07-29 Thread Craig Moynes
Could you use the find module to get the list of matching files? It is only available in v2.0, I have previously used the command module to execute a find on a remote system to get a list of files, then used the file module to check the state. On Wednesday, July 29, 2015 at 2:12:35 PM UTC-4,

[ansible-project] Ansible 2.0 -- shade is required for this module

2015-07-29 Thread Chris Gordon
I'm trying to use the os_server module in Ansible 2.0 and get the following error: fatal: [jump]: FAILED! = {changed: false, failed: true, msg: shade is required for this module} Here's what I have: - Python 2.7.10 (Mac, installed via Homebrew) - Using a virtual environment. - shade installed

Re: [ansible-project] Re: azure required for this module error

2015-07-29 Thread rsimbirtsev
Ok, I run ansible-doc -l and it shows that azure is installed. less comes with NO WARRANTY, to the extent permitted by law. For information about the terms of redistribution, see the file named README in the less distribution. Homepage: http://www.greenwoodsoftware.com/less a10_server

Re: [ansible-project] Re: jsonfile fact caching error: error, fact_caching_connection is not set, cannot use fact cache

2015-07-29 Thread Brian Coca
docs are wrong, location doesn't exist, i'll fix the docs On Wed, Jul 29, 2015 at 3:40 PM, senorsmile senorsm...@gmail.com wrote: There is no such keyword according to the docs: http://docs.ansible.com/ansible/playbooks_variables.html#fact-caching I can't even tell what it would want to be

Re: [ansible-project] Re: jsonfile fact caching error: error, fact_caching_connection is not set, cannot use fact cache

2015-07-29 Thread senorsmile
Great. So, fact_caching_location should actually be fact_caching_connection This should be dumping some sort of json of cached facts into that directory, correct? When I run anything that gathers facts, the /tmp/ansible_facts/ dir is created. However, it contains no files and no actual

[ansible-project] jsonfile fact caching error: error, fact_caching_connection is not set, cannot use fact cache

2015-07-29 Thread senorsmile
I have added the following to ansible.cfg fact_caching = jsonfile fact_caching_location = /tmp/ansible_facts fact_caching_timeout = 86400 With these set, any attempts to use ansible or ansible-playbook (tried multiple different known working playbooks) fails with the error: error,

[ansible-project] Does the file module handle wildcards?

2015-07-29 Thread Willard Dennis
Hi all, Trying to write a task that ensures no files matching a wildcard are present in a given directory (and if so, delete them.) I've tried the following, both of which do not work: - name: Ensure that any default 'Wired connection' entry is deleted file:

[ansible-project] Re: jsonfile fact caching error: error, fact_caching_connection is not set, cannot use fact cache

2015-07-29 Thread senorsmile
I should add that both machines are using ansible 1.9.2. On Wednesday, July 29, 2015 at 12:27:46 PM UTC-7, senorsmile wrote: I have added the following to ansible.cfg fact_caching = jsonfile fact_caching_location = /tmp/ansible_facts fact_caching_timeout = 86400 With these set, any

Re: [ansible-project] Re: azure required for this module error

2015-07-29 Thread Martin
Hi, I think you need to look at this: * ansible azure module * azure Python library The former requires the latter to work. But both can be _installed_ separately. That doesn't mean anyone is useful to you without the other. Check your distribution docs for how to install packages. Or if it's

Re: [ansible-project] Does the file module handle wildcards?

2015-07-29 Thread Brian Coca
if no find module just use: shell: find ... On Wed, Jul 29, 2015 at 9:13 PM, Willard Dennis willard.den...@gmail.com wrote: Thanks for the tip, but not running 2.0 yet... No way to do this on 1.9? On Wednesday, July 29, 2015, Craig Moynes craig.moy...@gmail.com wrote: Could you use the

[ansible-project] ansible command or shell: vagrant add box ubuntu/trusty64

2015-07-29 Thread Phill Pafford
I can run this command from the command line and it runs fine, using Ansible command or shell I get an error - name: download vagrant box ubuntu/trusty64 command: vagrant box add ubuntu/trusty64 anyone else have this issue? -- You received this message because you are subscribed to the

Re: [ansible-project] Rolling deploys to groups of servers

2015-07-29 Thread Brian Coca
several, one way is: - hosts: app*_server1:app*_server2:app*_server3 serial: 3 -- 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] Re: How do I configure Ansible to run kickstart for RHEL VM's

2015-07-29 Thread Paul Markham
You can use variables for the username and password, then use Ansible vault to encrypt the file containing the variable definitions. On Thursday, July 30, 2015 at 4:58:06 AM UTC+10, Gerald Pruchniewski wrote: I found this link which provides a lot of great information

[ansible-project] Re: Ansible not pulling in group_vars

2015-07-29 Thread senorsmile
How are you setting the inventory (I assume the hosts folder contain your inventory files). Give us a sample of what's in the inventory files? On Wednesday, July 29, 2015 at 1:29:29 PM UTC-7, datsun80 wrote: I moved my inventory files to their own directory and now the group_vars are not

Re: [ansible-project] Does the file module handle wildcards?

2015-07-29 Thread Willard Dennis
Thanks for the tip, but not running 2.0 yet... No way to do this on 1.9? On Wednesday, July 29, 2015, Craig Moynes craig.moy...@gmail.com wrote: Could you use the find module to get the list of matching files? It is only available in v2.0, I have previously used the command module to execute

[ansible-project] ansible azure module - deletion of cloud services when deleting vm's

2015-07-29 Thread Patrick Crews
Hello, I have been working with the azure module: http://docs.ansible.com/ansible/azure_module.html and have found it very functional so far. The one request I would have is that the user be provided the option of also deleting the associated cloud service when deleting vm's. Otherwise, my

Re: [ansible-project] ansible azure module - deletion of cloud services when deleting vm's

2015-07-29 Thread Brian Coca
Open a ticket in the github issue tracker so this is 'on the list'. On Wed, Jul 29, 2015 at 9:46 PM, Patrick Crews glee...@gmail.com wrote: Hello, I have been working with the azure module: http://docs.ansible.com/ansible/azure_module.html and have found it very functional so far. The one

[ansible-project] Re: ansible command or shell: vagrant add box ubuntu/trusty64

2015-07-29 Thread Paul Markham
What error are you getting? -- 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] Re: List of list and variables

2015-07-29 Thread Guillaume Querso
thank you for all your replies. i changed the way i am organizing my file. now i do: my_files: - {path: '/data/ansible/testing1', name: 'test1.reg', ext: '.reg'} - {path: '/data/ansible/testing1', name: 'test1.lst', ext: '.lst'} so it is less readable but easier to access to a variable

[ansible-project] Re: Ansible v2.0 (master branch) not showing each item in with_items

2015-07-29 Thread Fotis Gimian
After doing a few fresh runs this evening with the newest master branch, I think that for me personally, the value of items being displayed is lost unless the output is progressive. In cases where I am installing say 20 packages with a single task, it's impossible to know what's currently

[ansible-project] Unable to establish SSH connection using Ansible

2015-07-29 Thread cmacrae
I'm working on a role to deploy my Ansible setup (sort of a 'master node' configuration - where I execute Ansible from). Issue Description I've encountered a rather strange issue: I'm able to SSH as the user I'm running Ansible as to systems within my infrastructure using key pair

Re: [ansible-project] Unable to establish SSH connection using Ansible

2015-07-29 Thread cmacrae
Ah! Not sure how I didn't catch that in the debug output! Thank you very much, after setting this in ansible.cfg, this now works. Cheers, I appreciate the help :) On Wednesday, 29 July 2015 12:32:36 UTC+1, Andrea Tartaglia wrote: Hi, From the full debug you can see ansible is using the

[ansible-project] Re: Unable to establish SSH connection using Ansible

2015-07-29 Thread cmacrae
Cheers Paul! This is now sorted - really appreciate the help - I'm not sure how I missed that in the debug output... On Wednesday, 29 July 2015 12:37:03 UTC+1, Paul Markham wrote: The problem looks to be that you're trying to ssh as user 'ansible' when running the ansible command, instead of

[ansible-project] Re: Unable to establish SSH connection using Ansible

2015-07-29 Thread Paul Markham
The problem looks to be that you're trying to ssh as user 'ansible' when running the ansible command, instead of user 'root'. Using '-e remote_user=root' sets a variable, not a configuration option. Try specifying remote_user=root in your ansible.cfg, setting environment variable

Re: [ansible-project] how to abort execution upon a single fail on any host

2015-07-29 Thread Serge van Ginderachter
On 29 July 2015 at 14:49, Leon Xie qdxiaoli...@gmail.com wrote: max_fail_percentage: ​Perhaps ​any_errors_fatal: true might help? (btw Seems undocumented) -- You received this message because you are subscribed to the Google Groups Ansible Project group. To unsubscribe from this group and

[ansible-project] Re: Problem with var within a playbook

2015-07-29 Thread KSS
Strangely, if I use ; ip: {% for host in *play_hosts* %}{{ hostvars[host]['ansible_default_ipv4']['address'] }}{% if not loop.last %},{% endif %}{% endfor %} This all works across both tasks (or both plays, if split it into two plays) whereas using groups['all'] fails on the second task On

Re: [ansible-project] how to abort execution upon a single fail on any host

2015-07-29 Thread Leon Xie
thanks a lot for your suggestion. I had a try by adding any_errors_fatal: true. however, it doesn't work. ++ - hosts: aa max_fail_percentage: 0 any_errors_fatal: true roles: - stop_server - hosts: allhosts

[ansible-project] Re: ERROR: Invalid ini entry

2015-07-29 Thread Юра Фролов
Are there any fresh ideas? I'm confused, if everything is correct, why does not work? Which repository can use for upgrade ansible? -- 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

Re: [ansible-project] Run ansible playbook in uninitialized env?

2015-07-29 Thread Brian Coca
user: {{ lookup('env','USER')|default('root') }} On Wed, Jul 29, 2015 at 10:39 AM, Valeriy Solovyov weldpua2...@gmail.com wrote: Hello, I use some script that executes a ansible playbook from upstart. If I use lookup for variable playbook/task/defaults/main.yml: user: {{ lookup('env','USER')

Re: [ansible-project] PEP8 compliance in codebase

2015-07-29 Thread Toshio Kuratomi
Some style changes don't affect code now but they can have an adverse impact in the future. Indent falls into this category. For a language that defines blocks via indentation, python is very lenient about indentation so many things work but later code additions make those indentation levels

[ansible-project] Run ansible playbook in uninitialized env?

2015-07-29 Thread Valeriy Solovyov
Hello, I use some script that executes a ansible playbook from upstart. If I use lookup for variable playbook/task/defaults/main.yml: user: {{ lookup('env','USER') }} home: {{ lookup('env','HOME') }} It will the empty variables. Because upstart doesn't provide root or etc env. My question is

Re: [ansible-project] how to abort execution upon a single fail on any host

2015-07-29 Thread Leon Xie
Hi Serge, your suggestion about any_errors_fatal works for the hosts that in a single play. if there is another play and one of the hosts in the play is not in the hosts that marked as any_errors_fatal, the tasks in this play will also be executed. On Wednesday, July 29, 2015 at 8:54:59 PM

[ansible-project] how to abort execution upon a single fail on any host

2015-07-29 Thread Leon Xie
hi all, I have the below playbooks: +++ - hosts: aa max_fail_percentage: 0 roles: - stop_server - hosts: allhosts max_fail_percentage: 0 roles: - backup_data - hosts: localhost max_fail_percentage: 0 roles: -

Re: [ansible-project] Re: Ansible Tower: sudo task on localhost job failed

2015-07-29 Thread Bill Nottingham
Do Hoang Khiem (dohoangkh...@gmail.com) said: This problem occurred if I set connection: local in playbook, I often use it when running local playbook from command line, if remove that line the playbook runs successfully from Ansible Tower. So question: Doesn't Ansible Tower run playbook