Comments on Ansible Guide: The Ad-Hoc Command
The Ad-Hoc command is the one-liner ansible command that performs one task on the target host. It allows you to execute simple one-line task against one or group of hosts defined in the inventory file configuration.
5 Comment(s)
Comments
Hi Arul, Thanks for useful info. nice article!
What is "hakase-testing" in the command.
Husain.
hola que tal Husain "hakase-testing" es un archivo en cual esta las ip de los servidores que esta automatizando es lo mismo que "hosts", SLDS
Thanks Bro
This is a better Stuff for Strarting Ansible Thanks a Lot
Good job ! Keep it up.
My code to stop and start a service ssh is(main.yml file):
- name: Stop and Start Service
hosts: localhost
tasks:
- name: Stop ssh
service:
name: ssh
state: stopped
enabled: yes
- name: Started ssh
service:
name: ssh
state: started
enabled: yes
But I am not able to succeed in passing the test case. Anybody please help.
Mail: [email protected]