Skip to main content

Ansible

Ansible is a powerful open-source automation platform and configuration management tool used for IT infrastructure orchestration, application deployment, and system administration. It enables organizations to automate the provisioning, configuration, and management of servers, network devices, cloud resources, and applications across their entire infrastructure through agentless automation.

CategoryInfrastructure as code
DirectionQuery source
Sign-inNo Authentication
Query languagesSQLite
Tables4
Query templates17
Websitehttp://ansible.com

Before you start​

Ansible needs no credentials — Huntbase queries it without signing in.

Watch out for
  • A pattern of * matches every file in the path, including files that aren't playbooks. Use narrower patterns such as *.yml and *.yaml.

Connect Ansible​

  1. Go to Connections and click New connection, or click New connection on the Ansible product page.
  2. On Product, pick Ansible and choose the Owner.
  3. On Details, give the connection a Name and, optionally, a Description.
  4. On Connect, fill in the settings and credentials described below.
  5. On Verify, review the summary and click Create & check.

For everything else on the setup page — saving a draft, I'll do this later, and what each check result means — see Connections.

Settings​

Where your Ansible lives:

FieldRequiredNotes
Playbook File PathsNoWhere to find your playbooks: a local directory, a Git repository URL or an S3 bucket URL. Wildcards are allowed, and ** matches recursively, such as *.yml.
Inventory File PathsNoWhere to find your inventory files, such as /etc/ansible/hosts. The same sources and wildcards as Playbook File Paths apply.

Credentials​

The only Method is No Authentication. Enter a Credential label (for example Production), then fill in:

No fields — choose this method to connect without credentials.

Query it​

Once connected, Ansible can serve these languages in a query tab, and Scout can use it when you ask in Auto:

LanguageUse it for
SQLiteSQL over the 4 tables listed below, alongside every other connected source.

Example: SQLite​

List all Ansible hosts with ports and variables — Explore which hosts are defined in the Ansible inventory along with their respective ports and variable configurations.

select
name,
port,
vars
from
ansible_host;

Ansible ships with 17 query templates. Find them in Library › Queries — see Query templates.

Tables​

Ansible adds 4 tables. Browse their columns from Schema in the query bar's ⋯ menu.

All 4 tables
TableContains
ansible_groupLists logical grouping of hosts
ansible_hostHost refers to a specific machine or device that Ansible can manage and operate on
ansible_playbookAnsible playbook
ansible_taskTasks defined in an Ansible playbook

Next steps​