CloudBees action: Run Ansible Playbook

1 minute read

Use this action to run Ansible playbook, an open-source automation tool used in configuration management and infrastructure as code.

All CloudBees action repositories are listed at CloudBees, Inc. on GitHub.

Inputs

Table 1. Input details
Input name Data type Required? Description

url

String

Yes

The URL of Ansible AWX or AAP that has the REST APIs exposed.

token

String

Yes

An API token generated with the appropriate read or write access.

job_template_name

String

Depends

The name of the job template with the Ansible playbook.

workflow_job_template_name

String

Depends

The name of the workflow job template for the workflow configured on AWX or AAP.

Usage example

In your YAML file, add:

- name: Trigger ansible actions uses: cloudbees-io/ansible-run-job@v1 with: url: ${{ ANSIBLE_AWX_OR_AAP_URL }} token: ${{.API_TOKEN }} job_template_name: "sample job template name" # Or workflow_job_template_name: "sample workflow job template name"