Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What are ad-hoc commands? Give an example.

Answer Posted / Pradip Yadav

"Ad-hoc commands in Ansible refer to standalone or one-off commands that can be executed on remote hosts without creating a playbook. They are useful for tasks that don't require repetition across multiple hosts. An example of an ad-hoc command is running a shell command on a specific host:n[
"ansible all -m shell -a 'uname -a' "]

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What features does the ansible tower provide?

2


How is ansible different from puppet?

3


How does configuration management is help an organization?

2


How to generate crypto passwords for the user module?

2


Why is ‘{{ }}’ notation used? And how can one interpolate variables or dynamic variable names?

2


What does fact mean in ansible?

4


Can you copy files recursively onto a target host? If yes, how?

3


How can I display all the inventory vars defined for my host?

2


How can I set the path or any other environment variable for a task or entire playbook?

2


Can you build your own modules with ansible?

2


How can one interpolate variables or dynamic variable names?

2


How do I see all the inventory vars defined for my host?

2


Is it possible to build our modules in ansible?

2


How can you create a lamp stack and deploy a webpage by using ansible?

3


How to keep secret data in playbook?

2