Skip to content

App Overview

This document introduces the Nautobot Ansible Automation app and highlights the key details you need to know before deploying it in your Nautobot environment.

Note

Throughout this documentation, the terms app and plugin are used interchangeably.

Description

This app integrates Nautobot with AWX or Ansible Automation Platform (AAP) in the following ways:

  • Discovers AWX job templates, including their Survey Specs.
  • Generates Nautobot job classes for each template, creating forms that mirror the AWX surveys.
  • Allows operators to launch AWX playbooks from inside Nautobot, leveraging Nautobot's RBAC, scheduling, and job-history features.

More technically, the app:

  1. Syncs with the AWX API and fetches job templates and surveys
  2. Converts each survey question to the closest Nautobot JobVar type (see Field Mapping)
  3. Creates an in-memory subclass of BaseRunAnsibleJobTemplateJob and registers it
  4. Exposes the new job under Jobs → Jobs, relaying the variables to AWX and starting the playbook when the job runs
  5. Imports past job runs and logs from AWX into Nautobot for auditing and traceability

Is this app for me?

You may find this app particularly useful if you fall into one of the following categories:

  • Network / Automation Engineer who already operates AWX/AAP and wants a consolidated way of running automation workflows from Nautobot
  • Platform Administrator looking to reuse Nautobot's permissions, scheduling, and job-history features for existing playbooks
  • DevOps Engineer seeking tighter integration between network source-of-truth data in Nautobot and configuration automation in Ansible

Nautobot Features Used

Jobs

Nautobot Ansible jobs are Ansible job templates wrapped to behave as a Nautobot job. This gives several benefits:

  1. Familiar Nautobot job interface: Standardized Nautobot UI lets your Ansible Automation Platform instance do the heavy lifting.

  2. Native Nautobot features: Being Nautobot jobs, they fit perfectly into Nautobot's single-pane-of-glass workflow, allowing you to use built-in features such as scheduling, execution history, job buttons, and RBAC.

  3. Job parameters: They can be run like any other Nautobot job, with custom parameters per invocation. The job parameters are automatically generated from the AWX job template survey, so users see a familiar form in Nautobot that matches what they would see in AWX.

  4. Ease of import for existing playbooks: For those already automating with Ansible, Nautobot Ansible jobs are just a bonus. You may have experience defining Nautobot jobs by writing custom job classes. With the Ansible automation integration, you can skip this step—Nautobot uses metaprogramming to automatically generate job classes for you, so you do not have to write any code.

Scheduling and Approval

Nautobot Ansible jobs can be scheduled for a later date or require approval, independent of AWX's scheduling and approval features (which are not utilized in this integration). Once approved, Nautobot triggers the job execution in AWX. For details, see the documentation on job scheduling and approvals in Nautobot.

Job Runners

Nautobot Ansible jobs are enqueued and executed by configurable job runners (work queues). This reduces the unpredictable effects of race conditions in your network, especially when other automation tooling is being used. Managing these runners from Nautobot puts you in control of job scheduling and concurrency.

For more details on running jobs and managing queues, see the Core section on Nautobot Task Queues.

Job History

Nautobot mirrors your AWX job history, combining it with standard Nautobot run records, giving you a single place to find all job execution data. As part of the synchronization process, this app automatically imports past job runs from AWX into Nautobot for auditability and historical tracking.

Every time you refresh the job templates on the Ansible Controller, Nautobot discovers new or updated Job Templates in AWX. For each template that has been imported, Nautobot generates or updates the corresponding dynamic Job class. Nautobot also fetches and stores past job executions (status, timestamps, logs, etc.) that were run directly in AWX - even if Nautobot was not used to launch them.

The history only includes jobs within a configured retention period (e.g., 30 days), and skips duplicates already stored in Nautobot.

Imported data includes:

  • Job status (e.g., successful, failed)
  • Start and finish timestamps
  • Survey variables (when available)
  • Full job stdout log
  • Job events

This feature is always enabled and ensures Nautobot stays in sync with real-world execution history, regardless of whether jobs were run via Nautobot or directly via AWX.

AWX / Ansible Automation Platform Features Used

Job Templates

AWX Job templates are blueprints from which jobs are created. In Ansible AWX/AAP, job templates define which playbook to run, which inventory to use, and other runtime parameters. In Nautobot, these templates are exposed through the Nautobot job interface.

Jobs

Ansible (AWX/AAP) provides its own UI job runner and executes playbooks much like running ansible-playbook from the CLI; AWX/AAP also supplies logging, access control, and job definitions.

Current Limitations

  • Password survey questions are not currently supported.
  • Numeric validation (integer, float) is deferred to AWX because those question types rely on min_length / max_length, not numeric ranges.
  • Sync is read-only, so template creation or updates must still be performed in AWX/AAP.

While the Ansible Automation App does not intend to replace AWX/AAP, it helps bring your automation workflows right into your source of truth.

Getting Started (Summary)

  1. Install the app.
  2. Create an Ansible Controller object pointing to your AWX/AAP instance (with a Secrets Group for credentials).
  3. Run Refresh job templates from Ansible Controller.
  4. Navigate to Jobs → Jobs, pick a template, fill the mirrored survey form, and click Run.
Nautobot and Ansible AWX/AAP relationship diagram Nautobot and Ansible AWX/AAP relationship diagram
Figure: Connection between Nautobot and Ansible AWX/AAP.

Now you are ready to start driving your AWX playbooks from Nautobot! Read the full Getting Started guide to learn more.