Multiple linux hosts require to execute same command in deployment plan

ramesh gowru
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 13, 2019

Hi Team , 

I have 10 Linux hosts require to run same command at a time. Could you please suggest best way to do this scenario . I tried using ssh module in tasks but I have to create 10 tasks for 10 hosts to execute the same command. Is there a better way to do this ?

 

Thanks 

Ramesh 

1 answer

0 votes
ajeet_singh
Contributor
February 13, 2019

@ramesh gowru,

 try Ansible, it will help you

Once you have installed Ansible and added some hosts to the inventory file, typically /etc/ansible/hosts . you can try to connect to your hosts. By default a connection will be made with ssh keys, but you can also specify a username and password.

https://networklore.com/ansible/

 

Thanks,

Ajeet

ramesh gowru
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 13, 2019

@ajeet_singh

 

thanks for the quick reply, I want to include restarts as a part of  deployment job . +

 

Thanks

ramesh 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events