Running tasks from the console
Run ad-hoc tasks on target machines to upgrade packages, restart services, or perform any other type of single-action executions on your nodes.
When you set up a job to run a task from the console, the orchestrator creates a job ID to track the job, shows you all nodes included in the job, and runs the tasks on those nodes in the appropriate order. Puppet compiles a new catalog for each node included in the job.
There are three ways to specify the job target (the nodes you want to run tasks on):
-
A static node list
-
A Puppet Query Language (PQL) query
-
A node group
You can't combine these methods, and if you switch from one to the other, the target list clears and starts over. In other words, if you create a target list by using a node list, switching to a PQL query clears the node list. You can do a one-time conversion of a PQL query to a static node list if you want to add or remove nodes from the query results.
Run a task on a node list
Create a list of target nodes when you need to run a task on a specific set of nodes that isn't easily defined by a PQL query.
Install the tasks you want to use.
Make sure you have permission to run the tasks.
Make sure you have access to the nodes you want to target.
Run a task over SSH
Use the SSH protocol to run tasks on target nodes that do not have the Puppet agent installed.
Install the tasks you want to use.
Make sure you have permission to run the tasks on all nodes.
Run a task over WinRM
Use the Windows Remote Management (WinRM) to run tasks on target nodes that do not have the Puppet agent installed.
Install the tasks you want to use.
Make sure you have permission to run the tasks on all nodes.
Run a task on a PQL query
Create a PQL query to run tasks on nodes that meet specific conditions.
Install the tasks you want to use.
Make sure you have access to the nodes you want to target.
Make sure you have permissions to run tasks and PQL queries.
Add custom PQL queries to the console
Add your own PQL queries to the console and quickly access them when running jobs.
Run a task on a node group
Similar to running a task on a list of nodes that you create in the console, you can run a task on a node group.
Install the tasks you want to use.
Make sure you have permission to run the tasks.
Make sure you have access to the nodes you want to target.
Schedule a task
Schedule a job to run a task at a particular date and time or on a regular schedule.
Install the tasks you want to use.
Make sure you have access to the nodes you want to target.
Stop a job in progress
You can stop a job if, for example, you realize you need to reconfigure a class or push a configuration change that the job needs.
When you stop an on-demand Puppet run, runs that are underway finish, and runs that have not started are canceled.
- In the console, go to the Jobs page and select the Puppet run tab. From the list of jobs, find the one you want and click Stop.
- On the command line, press CTRL + C.
Delete a scheduled job
Delete a job that is scheduled to run at a later time.
- In the console, open the Jobs page.
- Click the Scheduled Puppet Run tab.
- From the list of jobs, find the one you want to delete and click Remove.