Ansible Ad-Hoc Commands

As per the Ansible documentation:

An ad-hoc command is something that you might type in to do something really quick, but don’t want to save for later.

For example, if you want to you can test a module, (e.g IOS_Facts), without having to write a Playbook by using Ad-Hoc commands such as this:

Here is another example, this time using the IOS_command module:

Knowledge Base

See the Ansible section of my Knowledge Base for more information.

As always, if you have any questions or have a topic that you would like me to discuss, please feel free to post a comment at the bottom of this blog entry, e-mail at will@oznetnerd.com, or drop me a message on Twitter (@OzNetNerd).

Note: This website is my personal blog. The opinions expressed in this blog are my own and not those of my employer.

One thought on “Ansible Ad-Hoc Commands

  1. Thanks for taking the time to post this. There isn’t a lot of info on syntax for ad-hoc commands out there, and this really helped. :)

Leave a Reply