[ansible-project] Re: ansible windows raw module no response?

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
An optional configurable timeout would be nice, but I have some tasks that run for over 60 minutes so I would not want a short default. Can you use Remote Desktop to check if your program is well perhaps? On Monday, August 1, 2016 at 2:02:45 PM UTC+1, fcx...@gmail.com wrote: > > Thanks for your

[ansible-project] Re: Ansible executes task regardless of conditional

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
This isn't a pattern I use but I just wonder if you need to ensure that the list of hosts you are creating is held as a list set_fact: my_group: "{{ just_created | list }}" hosts: "{{ my_group }}" or possibly even On Monday, August 1, 2016 at 4:04:37 PM UTC+1, Trond Hindenes wrote: > > As fa

[ansible-project] Re: Why a progress over when ansible exec all tasks on windows?

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
I think that is just the way windows remoting works - when you log out it kills any processes you have created (similar to when you log out of a remote desktop window, rather than just disconnect). It is definitely possible to get your java jar program to run if you set it up to run as a window

Re: [ansible-project] Re: Issue with Ansible

2016-08-01 Thread GBANE FETIGUE
thanks done On Monday, August 1, 2016 at 9:17:46 PM UTC-4, Stephen Granger wrote: > > Are you using the uri module mentioned previously? if the failure is an > ansible task error, you can use the ignore_errors statement in your task > > - name: get url > uri: > ...snip... > ignore_errors

[ansible-project] Re: ansible 2.1 setup fails with this module requires key=value arguments (['<>'])

2016-08-01 Thread Adam Grant
Hi Roman, I believe you are seeing this: FAILED! => {"changed": false, "failed": true, "msg": "this module requires key=value arguments (['<>'])"} because those 2 servers are sourcing local out-of-date ansible.egg files (in their easy-install.pth)? It was the case for me. This seems to be crea

Re: [ansible-project] Re: Issue with Ansible

2016-08-01 Thread Stephen Granger
Are you using the uri module mentioned previously? if the failure is an ansible task error, you can use the ignore_errors statement in your task - name: get url uri: ...snip... ignore_errors: true On 1 August 2016 at 17:35, GBANE FETIGUE wrote: > Thanks, it works but failed running I u

Re: [ansible-project] Re: Issue with Ansible

2016-08-01 Thread GBANE FETIGUE
Thanks, it works but failed running I used the status code 302 but I got the response how can I skip the failure? On Monday, August 1, 2016 at 3:41:45 PM UTC-4, Kai Stian Olstad wrote: > > On 01. aug. 2016 20:47, GBANE FETIGUE wrote: > > Here is the full response > > "deployment.stdout": "

[ansible-project] Re: Linode Module: StackScripts?

2016-08-01 Thread Jonathan Duncan
On Wednesday, July 27, 2016 at 12:19:28 PM UTC-6, Jonathan Duncan wrote: > > It appears that in the linode module there is no mechanism currently in > place for specifying a stackscript for the linode to use. Is this something > in the works? Seems like a pretty significant missing feature. > D

Re: [ansible-project] Issue with Ansible

2016-08-01 Thread Alex Leonhardt
Hi, Without trying to sound too direct (or even rude), have you read the message returned at all or are you relying on the people here doing that for you? Tomcat returned: HTTP Status 500 - org.codehaus.jackson.JsonParseException: Unexpected character ('"' (code 34)): was expecting a colon to sep

[ansible-project] Re: WinRM timeout for VMWare Tools Install

2016-08-01 Thread Matt Davis
Ansible 2.2 is scheduled to ship with async support for Windows (I'm putting the finishing touches on it now), which would be the right solution to this if you're unable to otherwise defer the NIC bounce. -Matt On Friday, July 29, 2016 at 4:10:03 PM UTC-7, Matt Betts wrote: > > I've got a basi

[ansible-project] Re: Windows playbooks causes cryptographic, windows remote management services to crash

2016-08-01 Thread Matt Davis
I've heard one other report of this happening a few weeks ago (but was via Ansible support and I didn't know who the customer was- maybe it was also you?) The services in question share the winrm host process, so not surprising that they're the ones going down. pywinrm 0.2.0 could definitely

[ansible-project] How to create a dynamic group using group_by and register a custom variable name

2016-08-01 Thread GANA SAGAR
0down votefavorite How to create variable group based on ip address-range in ansible inventory groups ? I have two groups of servers in different location. I want to create the two groups based on

[ansible-project] Re: with_dict expects a dict - when evaluating a variable in ansible 2.0+

2016-08-01 Thread 'Florian B' via Ansible Project
The solution is to address the variable like this (vars['variableName']): - name: Loop command: echo {{ item.key }} with_dict: "{{ vars[input|lower|regex_replace(' ','')] }}" Am Dienstag, 31. Mai 2016 14:12:52 UTC+2 schrieb Florian B: > > Hi everyone, > > I'm trying to get this

Re: [ansible-project] Re: Issue with Ansible

2016-08-01 Thread Kai Stian Olstad
On 01. aug. 2016 20:47, GBANE FETIGUE wrote: Here is the full response "deployment.stdout": "Apache Tomcat/8.0.26 - Error reportH1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D

Re: [ansible-project] Re: Issue with Ansible

2016-08-01 Thread GBANE FETIGUE
Here is the full response "deployment.stdout": "Apache Tomcat/8.0.26 - Error reportH1 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:22px;} H2 {font-family:Tahoma,Arial,sans-serif;color:white;background-color:#525D76;font-size:16px;} H3 {font-family:T

[ansible-project] How to define a base_dir var so you can use {{ base_dir }}/playbooks etc?

2016-08-01 Thread Patrick Laimbock
Hi, Ansible 2.1.1.0. Situation: Tim and Bob both deploy servers. Tim checks out the central ansible git repo to /home/tim/ansible while Bob checks it out to /home/bob/ansible. No special ansible.cfg is used by either. Problem: paths differ (/home/tim/ansible vs /home/bob/ansible) so you can

[ansible-project] Re: Windows playbooks causes cryptographic, windows remote management services to crash

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
I have run the ansible integration tests against a Server 2016 Tech Preview 5 build, which runs Powershell 5 and WMF 5.0. The only issue I have encountered so far is with uninstalling windows features - it seems there's a new version of the cmdlet that unininstalls features and seems to fail

Re: [ansible-project] Module for describing availability zones?

2016-08-01 Thread Allen Sanabria
You can write a module or a simple filter that will give you the availability zones in a region. https://github.com/linuxdynasty/ld-ansible-filters/blob/master/filter_plugins/aws.py#L202 So you can do something like this *zones: "{{ aws_region | zones() }}"* ​ On Mon, Aug 1, 2016 at 8:52 AM, wr

[ansible-project] Module for describing availability zones?

2016-08-01 Thread tom . moretto
I'm not sure if I'm overlooking this or not, but is there a module from Ansible that will describe the availability zones in my AWS region? I typically use us-east-1 as my default region, which has 5 available availability zones (A,B, C, D, E), out of which I can only use 4. I never know which

[ansible-project] Re: Windows playbooks causes cryptographic, windows remote management services to crash

2016-08-01 Thread Michael Perzel
Thanks I'll give 0.2.0 a try. We are running S2012R2 and powershell version 4. PS C:\Windows\system32> $PSVersionTable.PSVersion Major Minor Build Revision - - - 4 0 -1 -1 We are looking at powershell 5 for other reasons. Have you tried it out with ansi

[ansible-project] Openstack Dynamic Inventory Script

2016-08-01 Thread Govindaraj Venkatesan
Hi All, I tried setting multiple group names using nova meta tag as below but couldn't get that working using openstack.py dynamic inventory script for openstack. Can you please suggest? http://docs.ansible.com/ansible/intro_dynamic_inventory.html#example-openstack-external-inventory-script $n

[ansible-project] Re: Ansible executes task regardless of conditional

2016-08-01 Thread Trond Hindenes
As far as I can see, weird things start happening when using a variable as a target for hosts. If I do: hosts: just_created things look good, but if I capture that value in a variable instead, things fall to pieces: hosts: "{{ my_group }}" -- You received this message because you are subscri

Re: [ansible-project] Docker privileged containers

2016-08-01 Thread Alvaro Gil
Same here with `docker_container`, completely ignores `privileged: true`. On Monday, September 8, 2014 at 6:38:52 PM UTC-3, Michael DeHaan wrote: > > Can you share the output of ansible --version ? > > > > On Mon, Sep 8, 2014 at 4:07 AM, Abed Halawi > wrote: > >> I am using a playbook task to run

[ansible-project] Re: Ansible executes task regardless of conditional

2016-08-01 Thread Trond Hindenes
I'm just getting more confused by this. I updated my Ansible version to run from devel, this gave me some more info which I totally cannot make sense of: Here's the output running from devel: TASK [deploy_azurevm : Add vm to inventory (Linux)] * ERROR! the field 'hosts' has a

[ansible-project] Ansible executes task regardless of conditional

2016-08-01 Thread Trond Hindenes
Hi all, I have this weird thing inside a role, hopefully someone can straighten me out: My role is a custom made one, which performs Azure vm deployments, supporting both Linux and Windows. The last steps of the role are as follows: - name: debug debug: msg: "os_type: {{ os_type }} add_

[ansible-project] Using variable substitution with replace module and regex

2016-08-01 Thread Biswajit
Hi, I have two register variable in a play and want to replace one with another in a play. ___ - name: Editing the file replace: dest=/some/path regexp=^"{{ result.stdout }}." replace="{{ result2.stdout }}." backup=yes I want to

[ansible-project] Re: working on playbook to check file exists

2016-08-01 Thread Bill Carlson
Assuming that is your full playbook file, it needs more than tasks. Sample of a working file, read up for explanation of each portion: --- - hosts: system1,system2 tasks: - name: task1 stat: path=something register: stat_something There is also a method in a playbook that brea

Re: [ansible-project] Re: How do I use multiple ansible versions on the same machine for different playbooks that require specific versions?

2016-08-01 Thread Mike Biancaniello
I would also suggest python virtual environments. Although, I have also used Docker images for running Ansible. I create a Docker image with 'ansible' as the ENTRYPOINT, then create a shell script to execute 'docker run -it --rm []'. This will execute ansible inside the docker and use the pl

[ansible-project] Why a progress over when ansible exec all tasks on windows?

2016-08-01 Thread fcxjluo
ansible 2.2.0 I use raw module to run a bat,and the bat exec a jar,the jar will always run because it's a monitoring program。But when ansible exec the taks over,the jar will also over,why? -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To

[ansible-project] Why the process over after completing tasks in windows?

2016-08-01 Thread fcxjluo
I use raw module 'Start-Process -FilePath my.bat' my.bat exec a process collect logs.But when the tasks over,the process will be also end.I believe the process can run no problem. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscr

[ansible-project] Ansible alternative to jq select

2016-08-01 Thread kenjis15
Hi, I have command like this which picks up an element from a list of AWS hosted zones if hosted zone named "testinternal" is found in the list. If it finds it, extracts Id filed from that element. aws route53 list-hosted-zones | jq '.HostedZones[] | select(.Name == "testinternal.")' | jq -r "

[ansible-project] Re: ansible windows raw module no response?

2016-08-01 Thread fcxjluo
Thanks for your answer.I am not sure whether my program is well.But I think ansible should close the task if the task exec too long. 在 2016年7月28日星期四 UTC+8上午7:34:49,J Hawkesworth写道: > > If it is always running then may be you need to set up whatever the > run.bat does as a windows service. > Y

[ansible-project] Re: Scalable Spark Clusters (RE: Matt, Do you want your weekends back?)

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
Looks like there are several roles for installing Spark on Ansible Galaxy - probably a good starting point to see what others have done: https://galaxy.ansible.com/list#/roles?page=1&page_size=10&autocomplete=spark On Sunday, July 31, 2016 at 7:14:47 PM UTC+1, Matt Jude wrote: > > Good day, >

[ansible-project] Re: Windows playbooks causes cryptographic, windows remote management services to crash

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
Might be worth trying pywinrm 0.2.0 - even if its just because its much quicker than 0.1.1 However I don't think that by itself it will fix your problem though. Looking again the machines I'm running are actually S2012 R2 not S2012 and are mostly 2cpu 4Gb virtual machines. If yours are S2012 n

[ansible-project] Re: WinRM timeout for VMWare Tools Install

2016-08-01 Thread 'J Hawkesworth' via Ansible Project
Not doing this but interested to do so. Not quite the same but see this - https://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1018377 I think if you can persuade it not to restart networking immediately, then you can use the win_reboot: action to rest