[ansible-project] Re: List of running processes form multiple linux hosts using with_items

2018-04-12 Thread Bishwajit Samanta
I just changed the host as devops --- - hosts: devops gather_facts: no tasks: - name: Get the running process across the systems command: ps -ef register: output - name: Getting some details of systems local_action: copy content={{ output }} dest=/opt/{{

[ansible-project] Re: current run timestamp

2018-04-12 Thread Bishwajit Samanta
[defaults] I used callback_whitelist = profile_tasks You can set it in ansible.cfg. That can solve your problem i guess. On Wednesday, March 21, 2018 at 3:57:59 AM UTC+5:30, ordered...@gmail.com wrote: > > I want to set it up so there is a current ansible playbook run timestamp > set at the

[ansible-project] Re: need help to install Visual studio code on linux machine through Ansible

2018-04-12 Thread Varun Chopra
Your question is more suited for https://github.com/mhalano/ansible-role-visual-studio-code/issues On Wednesday, April 11, 2018 at 4:23:22 PM UTC+5:30, Vishal Mane wrote: > > I took a role to install vs code from github. now trying to run the role, > it gets executes successfully, but vs code

[ansible-project] Re: Hostnames with EC2 inventory plugin

2018-04-12 Thread oscar
Thank you very much for the information, and for the work! seems like ansible developers accepeted it, wich are great news. Regards, Oscar El miércoles, 11 de abril de 2018, 11:36:46 (UTC+2), flowerysong escribió: > > On Wednesday, April 11, 2018 at 3:19:51 AM UTC-4, os...@apartum.com wrote:

Re: [ansible-project] Ansible error : ERROR! The tasks/main.yml file for role 'xyz' must contain a list of tasks

2018-04-12 Thread Irfan Sayed
Thanks. Got it :) On Wednesday, April 11, 2018 at 11:56:52 PM UTC+2, Brian Coca wrote: > > `tasks:` should only appear in a play, not a tasks list for a role, > remove it and it should work. > > -- > -- > Brian Coca > -- You received this message because you are subscribed to the

[ansible-project] Is it possible to show anything graphical (like Zenity or the like) on remote nodes with a Ansible playbook?

2018-04-12 Thread Osqui
Hello. I have a playbook which removes Downloads folder in remote hosts user's home but I'd like to warn the user before he/she could cancel this. I've thought about prompting a question on his/her desktop screen with zenity. Is it possible to invoke graphical apps inside a playbook? If so,

[ansible-project]

2018-04-12 Thread ishita pandey
Hi team, I am trying to setup winrm connection to windows 12 but getting below error: <10.47.11.89> WINRM CONNECTION ERROR: the specified credentials were rejected by the server Traceback (most recent call last): File "/usr/lib/python2.6/site-packages/ansible/plugins/connection/winrm.py", line

[ansible-project] Re: unable to fit the piece of code in ansible

2018-04-12 Thread Bishwajit Samanta
Any one can suggest any idea please.. On Thursday, April 12, 2018 at 8:21:32 AM UTC+5:30, Bishwajit Samanta wrote: > > Hi all, > > I am a beginner in ansible. If anyone can help me in finding the answer. > It would be great. My problem was finding a phrase in ansible which one of > the person

Re: [ansible-project] Re: unable to fit the piece of code in ansible

2018-04-12 Thread Karl Auer
Can I suggest that you describe what you want to achieve. That is, describe the end result that you are seeking. That is more likely to get a useful response. Regards, K. On Thu, Apr 12, 2018 at 9:58 PM, Bishwajit Samanta < bishwajitsamanta1...@gmail.com> wrote: > Any one can suggest any idea

[ansible-project] Re:

2018-04-12 Thread Bishwajit Samanta
Share me your host file which you have configured in ansible, where you have decalared your connection type as winrm etc. May be i can look into it and help you. On Thursday, April 12, 2018 at 5:13:54 PM UTC+5:30, ishita pandey wrote: > > Hi team, > > > I am trying to setup winrm connection to

[ansible-project] Create a Azure VM with static private IP

2018-04-12 Thread Bubul Medhi
Hi, using Ansible, I want to create a Ubuntu VM in Azure with static private IP, i.e a predefined IP. Pls help. -- 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

[ansible-project] Re:

2018-04-12 Thread Bishwajit Samanta
i have configured once, this during the time i have change certain parameters in the host file, where i declared the connection type as winrm etc. If you can share your host file configuaration, may be i can look into it. On Thursday, April 12, 2018 at 5:13:54 PM UTC+5:30, ishita pandey wrote:

Re: [ansible-project] Re: vsphere wait for vm powered off

2018-04-12 Thread Zeljko Dokman
Hi, thank you for the info. one more question, for vsphere_guest module, how to know that "state" parameter should be referenced as "vm_state.ansible_facts.hw_power_status", this part a have not find in the documentation.? how is this contracted for all other parameters for particular module?

Re: [ansible-project] How to use the same dictionary to loop over two tasks? is it possible using block?

2018-04-12 Thread Kai Stian Olstad
On 12.04.2018 02:20, Tony Chia wrote: I would like to do this so that the win_iis_webbinding is called immediately after win_iis_website instead of calling win_iis_website,win_iis_website,etc then win_iis_webbinding, win_iis_webbinding, etc - block: - name: Create IIS site

Re: [ansible-project] Re: unable to fit the piece of code in ansible

2018-04-12 Thread Bishwajit Samanta
Thanks Karl, for your reply. Problem statement ::- My job is to find out the hostname which belongs to hostclass ess, which in this case the answer is host002. hostinfo: 'host001': ip: 192.168.43.10 hostclass: 'puppet' 'host002': ip: 192.168.43.11 hostclass: 'ess'

[ansible-project] Re:

2018-04-12 Thread Jordan Borean
You are also using Basic authentication over HTTP which isn't allowed by default on Windows and would be causing the rejection error. Please switch to a more secure authentication transport that can encrypt the messages over http like NTLM, Kerberos or CredSSP or use a HTTPS endpoint which

[ansible-project] Trying to create a new user and password for server login . SSH permission denied error.

2018-04-12 Thread poojavenkateshreddy
Hi, I am trying to create a new user and password for the server login. The user is created in /etc/passwd and also I can see the password entry in /etc/shadow however when I try to ssh through the new user I cannot login into the sever. What steps are missing in the following code. --- -

Re: [ansible-project] Ternary filter vs conditional expressions

2018-04-12 Thread rbarlik
On Wednesday, April 11, 2018 at 3:10:34 PM UTC+1, Brian Coca wrote: > > > The `ternary` filter is easier for people that are not familiar with > Python, but non programmers and those used to ternary structures in > other languages. > > I'm used to the different ternary structures from

Re: [ansible-project] Tacacs validation

2018-04-12 Thread 'Juraj Papic' via Ansible Project
Hello Brian, Thanks for that info, if I manage to configure the sshd to validate directly to the tacacas, do you this will fix the issue? Thanks. [image: cid:D5DA6341-AA78-4808-9639-F19B8AB3CBE8] *Juraj A. Papic* Arquitecto de Soluciones juraj.pa...@bghtechpartner.com Arias 1639/41.

Re: [ansible-project] Re:

2018-04-12 Thread Bishwajit Samanta
Check whether these configurations are there in your host file.. ansible_user: admin ansible_password: XXX ansible_winrm_scheme: https ansible_winrm_transport: credssp ansible_port: 5986 ansible_connection: winrm ansible_winrm_server_cert_validation: ignore validate_certs: false On Thu 12

Re: [ansible-project] Ternary filter vs conditional expressions

2018-04-12 Thread Brian Coca
Other people found it confusing and wanted something they could easily lookup up, like a filter. Once I added it, I stopped hearing complaints, so not sure how much that is worth other than anecdotal evidence. Use whichever way suits you best. -- -- Brian Coca -- You received

Re: [ansible-project] I am trying to disable a user and give no login access to the user.

2018-04-12 Thread Matt Martz
I typically do something like: - name: Disable the ubuntu user user: name: ubuntu password: "!" shell: /usr/sbin/nologin - name: Remove the ubuntu users ssh key file: path: /home/ubuntu/.ssh/authorized_keys force: yes state:

Re: [ansible-project] Tacacs validation

2018-04-12 Thread 'Juraj Papic' via Ansible Project
El tema que yo no estoy usando Ansible para conectar a Servidores lo estoy usando para networking. saludos y gracias. [image: cid:D5DA6341-AA78-4808-9639-F19B8AB3CBE8] *Juraj A. Papic* Arquitecto de Soluciones juraj.pa...@bghtechpartner.com Arias 1639/41. C1429DWA. Bs. As., Argentina. T.

Re: [ansible-project] Tacacs validation

2018-04-12 Thread Brian Coca
Como dije inicialmente, Ansible no hace la validación, pasa la información al conector y este as su vez lo pasa al sistema operativo, el cual valida el usuario y contraseña contra lo que esta configurado en la computadora. Si puedes entrar con usuario y contraseña o certificado, Ansible lo usará

[ansible-project] Is it possible to pass 'vars_prompt' variables from one playbook to another that would normally resemble passing arguments in functions?

2018-04-12 Thread EspressoBeanies
I'm wondering whether or not its possible to pass variables defined by 'vars_prompt' from one playbook to another when that other playbook is properly referenced in the first playbook. In other programming languages, this would be the equivalent of passing function arguments when the functions

Re: [ansible-project] Tacacs validation

2018-04-12 Thread 'Juraj Papic' via Ansible Project
muchas gracias, seguire buscando alguna forma. saludos y gracias. [image: cid:D5DA6341-AA78-4808-9639-F19B8AB3CBE8] *Juraj A. Papic* Arquitecto de Soluciones juraj.pa...@bghtechpartner.com Arias 1639/41. C1429DWA. Bs. As., Argentina. T. +54 11 5080-7400 M. +54 911 3445-6944 Skype

Re: [ansible-project] I am trying to disable a user and give no login access to the user.

2018-04-12 Thread POOJA VENKATESH
Thanks :) It works! On Thu, Apr 12, 2018 at 2:12 PM, Matt Martz wrote: > I typically do something like: > > - name: Disable the ubuntu user > user: > name: ubuntu > password: "!" > shell: /usr/sbin/nologin > > - name: Remove the ubuntu users

[ansible-project] How to sort ansible output

2018-04-12 Thread The Wanderer
Hi all, I have a couple of servers that are managed via ansible. On all of them, I have got a script - free.sh - that when run, outputs just the free memory, like - 5GB. This is not the free system RAM, but a value that's obtained by complex calculations done via the script. I can call the

[ansible-project] Trying to create a new user and password for server login . SSH permission denied error.

2018-04-12 Thread POOJA VENKATESH
Hi, I am trying to create a new user and password for the server login. The user is created in /etc/passwd and also I can see the password entry in /etc/shadow however when I try to ssh through the new user I cannot login into the server. What steps are missing in the following code? --- -

Re: [ansible-project] I am trying to disable a user and give no login access to the user.

2018-04-12 Thread POOJA VENKATESH
Thanks. It works :) On Thu, Apr 12, 2018 at 2:16 PM, Brian Coca wrote: > Or you can just expire the user : > > > - user: > name: thatguy > expires: "{{lookup('pipe', 'date +%s')}}" > > > > > > -- > -- > Brian Coca > > -- > You received this message because

Re: [ansible-project] Ansible Python API 2.0 - capture warnings

2018-04-12 Thread Suren Baskaran
Hey Brain Appreciate some pointers here Thanks, Suren VB From: Suren Baskaran Sent: Thursday, April 12, 2018 11:52:23 AM To: ansible-project@googlegroups.com; Ansible Project Subject: Re: [ansible-project] Ansible Python API 2.0 - capture

Re: [ansible-project] Tacacs validation

2018-04-12 Thread Brian Coca
No entiendo la pregunta, pero si quieres, podemos usar Español para entendernos mejor. -- -- 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

[ansible-project] Facts

2018-04-12 Thread Tcpip
Hi all, I have the following playbook --- - hosts: r2

Re: [ansible-project] Tacacs validation

2018-04-12 Thread 'Juraj Papic' via Ansible Project
Genial, Si puedo configura para que el sshd valide via tacacas, entonces Ansible podria hacer la validacion que necesito, ya que actualmente para un proyecto estoy buscando esta opcion . http://sen-wiki.blogspot.com.ar/2014/03/authenticate-linux-sshd-with-tacacs.html saludos y gracias.

[ansible-project] I am trying to disable a user and give no login access to the user.

2018-04-12 Thread POOJA VENKATESH
I am trying to disable a user and not remove it completely --- - hosts: target1 tasks: - name: disable the user become: yes user: name: random group: sudo state: absent When I run this playbook I see that the user is removed. Is there a way I can

Re: [ansible-project] Tacacs validation

2018-04-12 Thread Brian Coca
Es lo mismo, simplemente son servidores mas especializados, en cuanto la autentificación, no hay diferencia -- -- 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

[ansible-project] Tacacs validation

2018-04-12 Thread 'Juraj Papic' via Ansible Project
Hello, I would like to know if there's any chance to configure ansible to validate user/pass via tacacs , instead of hard coding the user/pass. I dont want to use vault. Thanks. -- *BGH* informa que todos los actos o

[ansible-project] Re: Ansible Playbook running for longtime/indefinitely for windows 2012 R2 Ansible Playbook

2018-04-12 Thread Ramanjaneyulu S
I have the same issue while using win_packageto install applications on remote windows servers. in the log ansible is giving status code 200 thrice and then status code 500 consistently. let me know, if you got any workaround. Thank you On Thursday, 8 March 2018 02:32:51 UTC-5, Namasivayam C

Re: [ansible-project] Re: vsphere wait for vm powered off

2018-04-12 Thread Kai Stian Olstad
On 12.04.2018 14:11, Zeljko Dokman wrote: Hi, thank you for the info. one more question, for vsphere_guest module, how to know that "state" parameter should be referenced as "vm_state.ansible_facts.hw_power_status", this part a have not find in the documentation.? how is this contracted for

Re: [ansible-project] Tacacs validation

2018-04-12 Thread Brian Coca
Ansible does not really validate user/pass, the connection system is responsible for it, normally delegating it to the login system. i.e ansible passes the info to ssh, sshd can delegate validation to login/pam. -- Brian Coca -- You received this message because you are subscribed to

Re: [ansible-project] Ansible Python API 2.0 - capture warnings

2018-04-12 Thread Suren Baskaran
Thanks for the prompt response Brian Any examples or references on how to integrate the display with playbook executor callbacks ? Appreciate your response Thanks, Suren VB From: ansible-project@googlegroups.com on behalf of