Chapter 9. Working with job templates
A job template combines an Ansible playbook from a project and the settings required to launch it. Job templates are useful to run the same job many times. Job templates also encourage the reuse of Ansible playbook content and collaboration between teams. For more information, see Job Templates in the Automation controller User Guide.
9.1. Getting started with job templates
As part of the initial setup, a Demo Job Template is created for you.
Procedure
-
To review existing templates, select
from the navigation panel. - Click to view its details.
9.2. Editing a job template
As part of the initial setup, you can leave the default Demo Job Template as it is, but you can edit it later.
Procedure
Open the template to edit it by using one of these methods:
- Click in the job template Details page.
-
From the navigation panel, select
. Click next to the template name and edit the appropriate details.
Save your changes.
- To exit after saving and return to the Templates list view, use the breadcrumb navigation links or click . Clicking does not exit the Details dialog.
9.3. Running a job template
A benefit of automation controller is the push-button deployment of Ansible Playbooks. You can configure a template to store all the parameters that you would normally pass to the Ansible Playbook on the command line. In addition to the playbooks, the template passes the inventory, credentials, extra variables, and all options and settings that you can specify on the command line.
Procedure
-
From the navigation panel, select
and click next to the job template.
The initial job start generates a status page, which updates automatically by using automation controller’s Live Event feature, until the job is complete.
For more information about the job results, see Jobs in automation controller in the Automation controller User Guide.
Additional resources
To learn more about these automation controller features or to learn about administration tasks and the controller API, see the following documentation sets: