2023-Nov-03-R11.1a

Integrate with Ansible Playbook

Ansible Task is a Runbook node where you can define target hosts, host groups, playbooks, inventory, and other relevant Ansible properties.

Complete the following steps to define an Ansible task and execute the Ansible node in a runbook.

  1. Click the   icon on the taskbar and select New Runbook.
  2. Graphical user interface

Description automatically generated

  3. Click Select Action or the   icon in the Runbook pane.
  4. Select Ansible Task under the Node Pane tab. Click Add.
  5. Graphical user interface, application

Description automatically generated

  6. In the Ansible Task node, define the following properties.

    Graphical user interface

Description automatically generated

    1. Click Traditional Device to select Traditional Device (default) or SDN Controller (Cisco ACI), depending on the network devices to which this Ansible task is applied.
    2. Graphical user interface, text, application  Description automatically generated

      Information Note: NetBrain only supports Cisco ACI in terms of SDN for now.
    3. Click the Manually Defined dropdown window to 1)manually define/import the playbook; 2) sync playbooks from the existing SCM; or 3) click SCM Manager to add a new SCM repo.
    4. Graphical user interface, application

Description automatically generated

      Information Note: SCM (Source Code Management) indicates synchronizing Playbook by SCM. See Sync Up Playbook from SCM for more information.
    5. Define the Playbook and Inventory per your need. See more details in Define the Playbook and Define the Inventory.
    6. (Optional) Define the Extra Variables required for playbook execution in the bottom text field.
    7. Information Note: Extra variables are passed into the command line using the --extra-vars (or -e) argument when executing the ansible-playbook command. You can follow Ansible’s document regarding the syntax format: https://docs.ansible.com/ansible/latest/user_guide/playbooks_variables.html#defining-variables-at-runtime

      Graphical user interface, text

Description automatically generated

  7. Execute Ansible Node in the Runbook.
  8. Information Note: Modifying device type or playbook creation method will clear the previously defined playbook, inventory, and extra variable configurations.