Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Dick Visser
You need to give more info. Playbooks, inventory, what are you trying to achieve, etc. On Tue, 1 Sep 2020 at 23:48, Erick Sun wrote: > > Host SSH key not recognized when trying to SSH into remote repository using > Ansible playbook. Remote repository was verified to have the correct SSH key > f

Re: [ansible-project] Permission issue with become

2020-09-02 Thread Dick Visser
You're trying to use /usr/sbin as a command, which won't work as this is a directory. Remove the 'args' stanza and instead use the full path to the shell command you want to run: tasks: - name: Update the packages using uptrack shell: '/usr/sbin/uptrack-upgrade -y' On Tue, 1 Sep

[ansible-project] Deploying application using WAR on Websphere using Ansible

2020-09-02 Thread Rachna Dodia
Hi Team Need your inputs on how to go forward with deploying application using WAR file on Websphere using Ansible. I cannot see any modules or playbooks related to the same. Looking for any suggestion or approach how to take this forward. Thanks, Rachna Dodia -- You received this message b

[ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Rachna Dodia
Need your inputs on how to go forward with deploying application using WAR file on Websphere using Ansible. I cannot see any modules or playbooks related to the same. Looking for any suggestion or approach how to take this forward. Thanks, Rachna Dodia -- You received this message because yo

Re: [ansible-project] find_output with filter

2020-09-02 Thread Nagesh sheregar
Hi Team, Any help is appreciated? Thanks On Tue, Sep 1, 2020 at 5:32 PM Nagesh sheregar wrote: > Hi Team, > > i would like to see only GREEN/RED in out put, can you please let me know > how i can filter it? > Playbook: > > - name: sddc health > command: /opt/vmware/sddc-support/sos --health-

Re: [ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Avinash Jadhav
Hi Rachna, Please find below playbook for war file deployment you need to changes your sources WAR and destination for Websphere Thank you Avinash - hosts: tomcatServer vars: - warName: helloworld.war - warRemotePath: /path/to/put/war tasks: - name: Download WAR to server sy

Re: [ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Abhijeet Kasurde
Check examples like 1. https://github.com/ansible/ansible-examples/blob/bedca7401f01411ec9d1b9231f5dc4a19ba12960/tomcat-memcached-failover/roles/tomcat/tasks/main.yml 2. https://github.com/ansible/ansible-examples/blob/59484f4fbfaa8d2c3938661c296ed6c9ae27d956/jboss-standalone/roles/

Re: [ansible-project] Deploying a application using WAR file on Websphere

2020-09-02 Thread Rachna Dodia
Thanks for the response. @Abhijeet , the example which you have shared have already available modules for JBOSS deployment. Where I cannot see or map any module as such for application deployment on Websphere. Thanks, Rachna Dodia On Wednesday, September 2, 2020 at 4:48:19 PM UTC+5:30 Abhij

[ansible-project] Using the filter_plugins in conditional when

2020-09-02 Thread Rafael Tomelin
Hi dear, I created the filter_plugin that check if running process and return true or false. This is an example: process_name|get_processes I want to create this task: *- name: start service* * shell: /usr/local/bin/my_script* * when: process_name|get_processes is false* But it seems to me t

Re: [ansible-project] copy file to host not in inventory

2020-09-02 Thread Ankit Vashistha
I am not sure if i clearly understood your question but, you might look into this: https://docs.ansible.com/ansible/latest/modules/add_host_module.html *Regards,* *Ankit* On Tue, Sep 1, 2020 at 9:25 PM william...@gmail.com < william.doss...@gmail.com> wrote: > Hi, sorry, I can't quite get my he

[ansible-project] Re: unzip to unarchive

2020-09-02 Thread Nuno Costa
I'm using something like below but I had to add *ignore_errors**: yes* due to what I believe is a bug in ansible and/or unarchive module. The task always fail but the files are extracted. Got this workaround from https://github.com/ansible/ansible/issues/27081#issuecomment-595842668 - name:

Re: [ansible-project] Generate HTML Table from Ansible Inventory File

2020-09-02 Thread Vladimir Botka
On Wed, 2 Sep 2020 07:17:42 -0700 (PDT) Xinhuan Zheng wrote: > ... if I want to reference all hosts in a > group, should I use > > {% for host in groups[group] %} If "group" is the name of the group then use {% for host in groups['group'] %} or, simply {% for host in groups.group %} If

Re: [ansible-project] Getting syntax error

2020-09-02 Thread 'Ramu Mathi' via Ansible Project
Any update on this? Please let me know. I need your help. On Wed, Sep 2, 2020 at 10:13 AM Ramu Mathi wrote: > Singh, We need roles here and we are calling the same way for others and > they are working well. Only for this host configuration I am getting that > error. Can we deep debug on this?

Re: [ansible-project] Using the filter_plugins in conditional when

2020-09-02 Thread Dick Visser
Isn't this what systemd is supposed to be for? If you deploy a proper systemd unit, you can use the service module. On Wed, 2 Sep 2020 at 15:43, Rafael Tomelin wrote: > Hi dear, > > I created the filter_plugin that check if running process and return true > or false. This is an example: > > proc

Re: [ansible-project] find_output with filter

2020-09-02 Thread Dick Visser
I would use the json output option of the sos tool and then filter things. Manipulating that big block of text will be very cumbersome and fragile. Fyi this list is not exactly a 'team' but more a collection of individuals willing to help. On Wed, 2 Sep 2020 at 13:13, Nagesh sheregar wrote: >

Re: [ansible-project] find_output with filter

2020-09-02 Thread Nagesh sheregar
Thank you so much for the info .. On Wed, Sep 2, 2020 at 12:35 PM Dick Visser wrote: > I would use the json output option of the sos tool and then filter things. > Manipulating that big block of text will be very cumbersome and fragile. > > Fyi this list is not exactly a 'team' but more a collec

Re: [ansible-project] Error:a bug: 'utf8' codec can't decode byte 0xa0 in position 588

2020-09-02 Thread Dick Visser
Please include the actual text and not some huge yet fuzzy photo. Also, you still did not include the playbook that triggers this error. So, send the actual playbook, and the text of the error (just using "copy/paste" should do). On Tue, 1 Sep 2020 at 14:25, erdivay singhal wrote: > > Hi stefen >

[ansible-project] Ansible task not starting up custom node.js script with either shell or command module

2020-09-02 Thread Sebastian Collins
Hi, Any ideas where I am going wrong here? I have a web server task which uses shell to start apache no problem: - hosts: webservers remote_user: root become_user: test become: True tasks: - name: Task18 - Start webservers back up shell: ./apache/bin/apachectl start

Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Erick Sun
Hello, thanks for taking a look! I am trying to install needed software on hosts running RHEL 7.x (Docker, Python, Intel Parallel Studio). During play to download Intel, the play is designed to ssh into and clone from remote Git repo. It has been verified that the local host' ssh key is know

Re: [ansible-project] Help with async tasks.

2020-09-02 Thread Guannan Sun
Thank you! Even I have not used gnu parallel before, I'll also take it into consideration. If have any progress, I'd like to share. Best reagards! 在2020年9月2日星期三 UTC+8 上午8:07:53 写道: > well other option (i used only once) is run the shell command with gnu > parallel . > its pretty amazing! but i

Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Dick Visser
Sounds like a permission issue somewhere. Can you manually sudo to whatever user your playbook is using and clone the repo? Key permissions ok? Correct user? On Wed, 2 Sep 2020 at 23:34, Erick Sun wrote: > Hello, thanks for taking a look! I am trying to install needed software > on hosts runn

Re: [ansible-project] Host SSH key not recognized when trying to SSH into remote repository using Ansible playbook

2020-09-02 Thread Dick Visser
Or: key is ok but it's not being used because of an ssh misconfig On Thu, 3 Sep 2020 at 06:44, Dick Visser wrote: > Sounds like a permission issue somewhere. > Can you manually sudo to whatever user your playbook is using and clone > the repo? > Key permissions ok? > Correct user? > > > > On Wed

[ansible-project] playbook to compare and update hostvars in host file

2020-09-02 Thread harsh chawda
Hello All, I am trying to update /etc/hosts file if there is any changes in the host extra variables by comparing it from a csv file [windows] Server01.test.com ansible_user="admin" ansible_password="password" Server02.test.com ansible_user="admin" ansible_password="Welcome" So suppose the pass