Re: [ansible-project] ansible check and diff mode not working

2020-07-15 Thread Shyam Sunder
mple exits online. Somehow its not working for me. I thought someone could guide with this. -Shyam On Wednesday, July 15, 2020 at 2:00:45 PM UTC+5:30, Stefan Hornburg (Racke) wrote: > > On 7/15/20 10:08 AM, Shyam Sunder wrote: > > Thanks for reply. Yes below is my intended config -

Re: [ansible-project] ansible check and diff mode not working

2020-07-15 Thread Shyam Sunder
e/latest/user_guide/playbooks_checkmode.html>) its mentioned that we can use these together.* -Shyam On Wednesday, July 15, 2020 at 12:55:23 PM UTC+5:30, Srinivas Naram wrote: > > Hello Shyam > > It is how the output is displayed. In your output updates are showing the > difference

[ansible-project] ansible check and diff mode not working

2020-07-14 Thread Shyam Sunder
Hi, I was going thru this post ( https://blog.networktocode.com/post/generating-diff-with-ansible/) where its mentioned that we can use check and diff mode together. I am trying to use that for gold config audit (audit pre decided config against what is present on device) for Cisco and Extre

Re: [ansible-project] Download Github file from Ansible

2020-06-19 Thread Shyam U
Using win_get_url and win_uri ? Thank you. Shyam On Fri, Jun 19, 2020, 7:02 PM Abhijeet Kasurde wrote: > Yes, > > https://raw.githubusercontent.com/user/repository/branch/filename > > > On Fri, Jun 19, 2020 at 6:51 PM shyam rpm wrote: > >> Hi, >> >> >

[ansible-project] Download Github file from Ansible

2020-06-19 Thread shyam rpm
Hi, Is it possible to download a Github file without Git module to a remote machine (windows) using win_get_url or win_uri module ? Thankyou, Shyam -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this grou

[ansible-project] CSV to JSON

2020-05-20 Thread shyam rpm
Hi, Is it possible to convert CSV file to JSON format using Ansible modules, I have searched for the modules have't found. Or else do we need to use any scripting language to achieve this powershell or python ? Thank you, Shyam. -- You received this message because you are subscrib

Re: [ansible-project] Re: copy j2 file to Json on windows server

2020-04-28 Thread shyam rpm
Hi Jordan, I have tried the suggested code but still have the same issue and it is not creating the file or updating the file content. - win_template: src: config.j2 dest: D:\config1.json Thanks and Regards, Shyam On Tue, Apr 28, 2020 at 2:52 PM Jordan Borean wrote: > Rem

[ansible-project] copy j2 file to Json on windows server

2020-04-27 Thread shyam rpm
quot;* *dest: "D:\\config1.json"* * remote_src: true* *Thank you,* *Shyam* -- 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 ans

Re: [ansible-project] Append data to json file using ansible modules

2020-04-11 Thread Shyam U
ig.json regexp : '^source_path' insertafter: '^service_id' line: '192.168.1.2\\data\\nonprod' state: present Thankyou, Shyam On Sat, Apr 11, 2020, 3:41 AM Dick Visser wrote: > It depends on your data. > Please post your json and tell what you

[ansible-project] Re: set object property using set_fact

2020-02-27 Thread Shyam Sunder
at 2:27:18 PM UTC+5:30, Shyam Sunder wrote: > > Hi, > > I am new to Ansible an trying to achieve this below. Is this possible to > set a dictionary property using key in Ansible. > > vars: > mydict: >keyA: > path: ‘path of device A’ &g

[ansible-project] set object property using set_fact

2020-02-27 Thread Shyam Sunder
Hi, I am new to Ansible an trying to achieve this below. Is this possible to set a dictionary property using key in Ansible. vars: mydict: keyA: path: ‘path of device A’ error_files: [] keyB: path: ‘path of device B’ error_files: []

[ansible-project] Ansible block + with_together

2019-07-22 Thread Shyam Sunder
Hi There, I am new with Ansible and still figuring out how to use with_together with block. UseCase: Trying to compare configuration of device A and device B. Below is a snippet from my script. - hosts: pairB connection: network_cli name: script to audit HSRP config of pair B device ta

[ansible-project] unable to copy large no.of files using win_copy module

2019-07-03 Thread shyam rpm
data" dest: "192.168.1.2\\backup\\" force: true remote_src: true become_method: runas become_user: "admin@adroot" become: true Thanks and regards, Shyam. -- You received this message because you are subscribed to the Google Groups "

[ansible-project] Unexpected RC while uninstallaing a package using win_package

2019-06-29 Thread shyam rpm
Hi All, Im trying to uninstall a package using win_package but getting the following error, Playbook is able to remove the software from the server but at the end Im getting this error. *"msg": "unexpected rc from install G:\\Program Files\\IBM\\cognos\\tm1_64\\uninstall\\uninst.exe: see rc, s

Re: [ansible-project] Launch instances from a file

2019-03-26 Thread shyam . rpms
t; > Here my requirement is to iterate the CSV file contents line by line and need > to launch the instances from the CSV file. > > Any suggestions please. > > Thank you, Shyam -- You received this message because you are subscribed to the Google Groups "Ansible Proje

[ansible-project] Launch instances from a file

2019-03-25 Thread shyam . rpms
Portnumber Portnumber Sample11122 2211 Sample21233 4321 sample3 4432 3321 Thank you, Shyam -- You received this message because you are subscribed to the Google Groups "Ansible Project" group.

[ansible-project] Re: How to save the O/P of ansible playbook into a file in windows enviroment

2019-03-04 Thread shyam . rpms
: copying the content to a file copy: content="{{ json_ooutput}}" dest=/path/to/destination/file_name Thanks and Regards, Shyam. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from

[ansible-project] How to save the O/P of ansible playbook into a file in windows enviroment

2019-03-03 Thread shyam . rpms
Hi All, I have a playbook, using REST API getting the details of a process in JSON format. I want to save that JSON o/p to a file in windows environment. Can any one please help me. sample playbook: --- - hosts: windows remote_user: admin tasks: - name: rest api win_uri: url: ht

[ansible-project] Re: Want to change the installatin path using win_package

2019-01-20 Thread shyam . awk
Hi Varun, I will try this. Thank you, Shyam > >>> -- 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...@goo

[ansible-project] Want to change the installatin path using win_package

2019-01-20 Thread shyam . awk
nd Regards, Shyam -- 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 emai

[ansible-project] is it possible to pass tags to tower-cli ?

2019-01-08 Thread shyam . awk
Hi, I'm triggering the Ansible tower job template using tower-cli. Is it possible to use the tags in tower-cli while triggering the template ? like the following. #tower-cli job launch --job-template 123 --tags test1,test2 Thanks and Regards, Shyam. -- You received this me

[ansible-project] How to check exit status of an application in windows ?

2018-10-14 Thread Shyam
Hi, Is it possible to check the exit status of an application in windows through playbook like Linux ? Thanks and regards, Shyam. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiv

Re: [ansible-project] Re: Want to access the server information from CSV file.

2018-10-11 Thread Shyam U
y > serverlist.csv -> https://pastebin.com/4JTtr2vv > > then play with using "when" to control task execution, like: > - name: dump my_server > debug: var=my_server > when: my_server == 'server1' > > > > On Thursday, October 11, 2018

Re: [ansible-project] Re: Want to access the server information from CSV file.

2018-10-11 Thread Shyam U
7;, 'Li file=elements.csv delimiter=, col=2') }}" and it is returning the hostname. I want to save the result hostname in a variable and will used to execute the tasks. Can you suggest ? > Thanks & Regards Shyam [image: http://r20.imgfast.net/users/2014/25/58/12/avatars/

[ansible-project] Want to access the server information from CSV file.

2018-10-10 Thread Shyam
Hi all, Im trying to access the server information from CSV file. Based on this information, I want to target the host. The CSV file contains the following information. based on this CSV file, when ever we pass the instance name using --extra-vars the task should execute on the corresponding s

[ansible-project] Re: Unable to process the JSON request in POST method

2018-09-28 Thread Shyam
Hi Kuladip, Thanks for your reply. I have tried the option still getting the same error. Any other suggestion please ? -- 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 a

[ansible-project] Unable to process the JSON request in POST method

2018-09-28 Thread Shyam
Hi, Unable process the JSON request in POST method can any one help. *---* *- hosts: windows* * remote_user: usern...@domain.com* * tasks:* * - name: POST a body to an endpoint* *win_uri:* * url: http://server_url_for_api/file.exe * * method: post* * user:

Re: [ansible-project] Unable to authenticate through CredSSP

2018-09-26 Thread Shyam U
Hi Jordan, Thanks for your replay. Issue got fixed, after enabling 'Enable-WSManCredSSP -Role Server' Thanks for your help. Shyam On Sun, Sep 23, 2018 at 1:05 PM Jordan Borean wrote: > You have to make sure CredSSP is enabled in the server roles with > 'Enable-WSMa

Re: [ansible-project] Unable to authenticate through CredSSP

2018-09-23 Thread Shyam
ol(host='x.x.x.x', port=5986): Max retries exceeded with url: /wsman (Caused by NewConnectionError(': Failed to establish a new connection: [Errno 111] Connection refused',))", "unreachable": true } == Do I need to do any changes a

Re: [ansible-project] Unable to authenticate through CredSSP

2018-09-23 Thread Shyam
> > Hi Ankit, > > Thanks for your reply. The user have all the admin rights. Still Im unable to connect to the remote host. Same error. -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop

[ansible-project] Unable to authenticate through CredSSP

2018-09-22 Thread Shyam
rm ansible_winrm_scheme: https ansible_winrm_transport: credssp ansible_winrm_server_cert_validation: ignore Thanks, Shyam -- 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

[ansible-project] Re: Unable to copy the files using the network path.

2018-09-20 Thread Shyam
os_delegation: true == Thank you, Shyam -- 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

[ansible-project] Unable to copy the files using the network path.

2018-09-20 Thread Shyam
Hello, Im unable to copy the files from the windows host to network path. Initially I tried to copy the files using NTLM authentication method and got the error as "Access denied". After using the Kerberos authentication method im able to copy the files successfully to the network path. Afte

Re: [ansible-project] Ansible Command Module Error

2017-03-14 Thread Shyam Yenna
true }, "module_name": "command" }, "rc": 7, "start": "2017-03-14 20:27:02.040525", "stderr": "", "stdout": "", "stdout_lines": [], "warnings":

[ansible-project] Ansible Command Module Error

2017-03-14 Thread Shyam Yenna
I am encountering issues while trying to execute below task in a playbook. - name: Setup OpenDJ command: "setup --cli --propertiesFilePath /tmp/opendjsetup.props --no-prompt" args: chdir: "{{ install_dir }}/opendj" #creates: "{{ install_dir }}/opendj/config" igno

[ansible-project] Ansible Get_url module response HTTP Bad Request

2017-03-01 Thread Shyam Yenna
penDJ Enterprise/3.0.0/OpenDJ 3 Zip/OpenDJ-3.0.0.zip", "url_password": "password", "url_username": "user", "use_proxy": true, "validate_certs": true }, "module_name&q

[ansible-project] Forgerock OpenAM Code Snippet

2017-02-24 Thread Shyam Yenna
I would like to implement Forgerock OpenAm if some one implemented can share code snippet. I could find source code url to download latest package without passing user credentials. Thanks Shyam -- You received this message because you are subscribed to the Google Groups "Ansible Pr

[ansible-project] postgresql_user module help

2017-02-07 Thread Shyam Yenna
a)\n File \"/usr/lib/python2.7/dist-packages/psycopg2/extras.py\", line 123, in execute\nreturn _cursor.execute(self, query, vars)\npsycopg2.ProgrammingError: conflicting or redundant options\n\n", "module_stdout": "", "msg": "MODULE FAIL

Re: [ansible-project] PostgreSQL 9.5 or Higher installation on Ubuntu 14.04 LTS

2017-01-31 Thread Shyam Yenna
Thanks Dick... I really appreciate all your help. --shyam On Tuesday, January 31, 2017 at 3:56:36 AM UTC-5, Dick Visser wrote: > > On 30 January 2017 at 22:31, Shyam Yenna > > wrote: > > Thanks for all replies... > > > > I understood clearly error. >

Re: [ansible-project] PostgreSQL 9.5 or Higher installation on Ubuntu 14.04 LTS

2017-01-30 Thread Shyam Yenna
postgresql-common >=158 & libpq5 >=9.5.5 on Ubuntu 14.04 LTS. I appreciate for all your valuable feedbacks Thanks Shyam -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving ema

Re: [ansible-project] PostgreSQL 9.5 or Higher installation on Ubuntu 14.04 LTS

2017-01-30 Thread Shyam Yenna
resql-contrib-{{ postgresql_version }}" Unable to install package as depends are not met. Technically i have added repository of postgresql 9.5, still i get dependencies not match with exact version number to proceed on installation. Thanks Shyam On Sunday, January 29, 2017 at 11:19:31 AM UTC-5,

Re: [ansible-project] PostgreSQL 9.5 or Higher installation on Ubuntu 14.04 LTS

2017-01-29 Thread Shyam Yenna
{ item }}" state: present update_cache: true environment: "{{ postgresql_env }}" when: repoadd.changed with_items: - "postgresql-common" - "postgresql-{{ postgresql_version }}" - "postgresql-client-{{ postgresql_ver

[ansible-project] PostgreSQL 9.5 or Higher installation on Ubuntu 14.04 LTS

2017-01-27 Thread Shyam Yenna
this issue i am unable to find below packages in default os packages. I appreciate your help. Thanks Shyam -- 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

[ansible-project] Re: Help on ansible tasks

2017-01-20 Thread Shyam Yenna
I have found my defect. Thanks for help and Enjoy coding... -- 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.

[ansible-project] Re: how to comment multiple lines in ansible playbook

2017-01-20 Thread Shyam Yenna
if your using linux machine. Use vi editor identify multi lines to comment and comment them : set number :10,20s/^/#/ -- 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

[ansible-project] Re: Help on ansible tasks

2017-01-20 Thread Shyam Yenna
I am unsuccessful debugging above things. I appreciate if someone can shed some light into the issue and bring me into light. I am currently using Ansible 2.2.0 Version installed on ubuntu 16.04 LTS. I am repeatedly running playbook multiple times during entire infrastructure playbook developme

[ansible-project] Help with filesystem module and apt_key

2017-01-08 Thread Shyam Yenna
I am trying to format attached volume of an instances it is throwing an error below. "changed": false, "failed": true, "invocation": { "module_args": { "dev": "/dev/xvdf", "force": false, "fstype": "ext4", "opts": "-t",

[ansible-project] Help on ansible tasks

2017-01-08 Thread Shyam Yenna
Please can someone help as i am having hard time to debug or troubleshoot below ansible module tasks. I am trying to format an ebs volume attached to an ec2 instance.i am getting below error. { "changed": false, "failed": true, "invocation": { "module_args": { "d

[ansible-project] Ansible Cloud Module

2017-01-04 Thread Shyam Yenna
I am trying to create a role for aws vpc creation. one of the task is to create an elastic ip address and associate that ip address to nat gateway instance. if i run multiple times playbook it is recreating elastic ip but i would like to find a viable solution to make it idempotent. Please can