[ansible-project] Re: Not able to connect windows server due to the Error "module_stderr": "An error occurred while creating the pipeline.\r\n"," while trying with win_ping

2018-09-17 Thread Jordan Borean
Can you run with `-v` as that will show more info on the connection process that can help identify your issue. -- 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

Re: [ansible-project] Debugging Roles vs Debugging plays

2018-09-17 Thread Brian Coca
formats dont change for tasks, the problem is you are running to tasks toghether - debug: msg: "before we run our role" - set_fact: server_hostname: "{{ server_hostname }} + [ '{{ item.0.server_category + item.1.server_numbers + location.short + 'V' }}' ]"

Re: [ansible-project] Trying Oracle database download to windows server 2012

2018-09-17 Thread Jordan Borean
You can store the download on your own web server and use win_get_url from there. The trouble isn't that Ansible is failing but that Oracle is hiding the actual download behind a license agreement. I've had success with adding the cookie value to the win_get_url header so Oracle presents you

Re: [ansible-project] Connection plugin with user configuration coming from a variable

2018-09-17 Thread Brian Coca
A variable is a variable, by the time the plugin gets it the origin is not discernible. So using the current pulgin config system you just need to either add an option that uses that variable as a config source or if you are using it for an existing option, add it there. myoption:

[ansible-project] Debugging Roles vs Debugging plays

2018-09-17 Thread Sloan Miller
I am having issues formatting a role, I am trying to use register: and debug. Can anyone show the the formatting for debugging roles with register in ansible. This is not working in a role: - name: Generate Hostnames for AD Group Names - debug: msg: "before we run our role"

[ansible-project] Re: Ansible Windows Deployment - 'Connection aborted.', error(104, 'Connection reset by peer')

2018-09-17 Thread Jordan Borean
You need both the hotfix and the registry keys set for the connection to break like this, having one or the other is not enough. Another thing to note is that this only applies to Server 2008, the 2008 R2 edition works just fine with TLSv1.2. So if this is the original 2008 version (and not

[ansible-project] Re: WinRM Connection Error

2018-09-17 Thread naga venkatesh naidu
+1 getting the same error, didn't get the solution yet. please post here if anyone resolved the following error. pip list : Package Version - ansible 2.6.4 asn1crypto 0.24.0 Babel

[ansible-project] Connection plugin with user configuration coming from a variable

2018-09-17 Thread Peter Horvath
Hi All, I am working on a custom connection plugin based on -- (99% the same) -- the built-in SSH connection type [1], which would need to take some configuration from playbook variables. Unlike the standard SSH plugin, this would use custom playbook variable names, hence I cannot use the

[ansible-project] Ansible Jinja Template Comparison

2018-09-17 Thread Krishna N
Greetings! How to compare when items are not in jinja template loop? with_items: "{{ runconfser.stdout_lines[0] }}" when: (item not in {src: 'ntprequired.j2'} and (item!="")) ios_config: lines: - "no {{ item }}" I am using roles. */templates/ntprequired.j2*: {% for

[ansible-project] Get-ScheduledTask not recognized?

2018-09-17 Thread aaldi
I'm trying to run ansible code to execute code on a windows machine. I do that by scheduling a task as a way of 'elevating' as mentioned in the documentation. This has worked previously, but now I switched to working with Windows 7 enterprise, and I've had several problems already. Currently,

[ansible-project] Not able to connect windows server due to the Error "module_stderr": "An error occurred while creating the pipeline.\r\n"," while trying with win_ping

2018-09-17 Thread Usha Rani
Hi, I am trying to do ping test to some windows machine using win_ping but getting the below error when i run the ping yml. $ansible win_prod -i /tmp/winhosts.yml -m win_ping -k [WARNING] Ansible is in a world writable directory (/tmp), ignoring it as an ansible.cfg source. SSH password:

[ansible-project] Ansible mail module: how to attach a file with a relative path?

2018-09-17 Thread Sabrina Lautier
Hi everyone, Is it possible to provide a relative path to a file as *attach* parameter of the ansible mail module? >From my tests and internet searches, it doesn't work: in my example, the playbook calls the task that is in directory structure ./roles/notify/tasks/send_email.yml and the file I

[ansible-project] Send commands via CLI over SSH to unsupported network device

2018-09-17 Thread sign@L
I need to send commands to 600 network devices (they are Fortinet Access Points) that have SSH enabled. Python is not available on the device, so I need to use something like network_cli. I've tried all the ansible_network_os options (ios, nxos, vyos, eos...), but none work. Is there a way of

Re: [ansible-project] Send commands via CLI over SSH to unsupported network device

2018-09-17 Thread Julian Kriel
Yeah, I struggled with this for a while. Found the expect module is what works. Look into it. On Mon, 17 Sep 2018, 12:57 sign@L, wrote: > I need to send commands to 600 network devices (they are Fortinet Access > Points) that have SSH enabled. Python is not available on the device, so I >

Re: [ansible-project] Send commands via CLI over SSH to unsupported network device

2018-09-17 Thread Julian Kriel
- name: Check CPU Load hosts: all connection: local gather_facts: yes tasks: - name: Get CPU Load expect: command: ssh admin@10.170.170.100 responses: ad...@xx.xxx.xx0.xxx's password: - xxx - '#': '"show platform cpu-load summary "'

[ansible-project] Re: Ansible mail module: how to attach a file with a relative path?

2018-09-17 Thread Sabrina Lautier
[I forgot to mention that the attached file path can change from one execution to another, that's why I cannot provide an absolute path] It works fine if I copy the attached file to a non-changing directory (e.g. /tmp), but the task fails if no attached file is provided. - name: Copy attached