Harness UI Approvals

Updated 2 weeks ago by Michael Katz

You can specify Harness User Group(s) to approve or reject a Pipeline or Workflow. During deployment, the User Group members use the Harness Manager to approve or reject the deployment.

The other approval mechanisms are:

Before You Begin

Step: Add an Approval Step in a Pipeline

In your Pipeline, in Pipeline Stages, click +. The following settings appear.

Select Approval Step.

Select Harness UI in the Ticketing System.

Select one or more User Group(s) to notify for the approval requests.

You can template this setting, turning it into a parameter. Just click the template button:

In a Pipeline or Workflow Approval step, clicking this button creates a variable named ${User_Group}. This is the default variable, but you can edit its name or replace the variable with a Service or Workflow variable, or even an Application Default variable.

When you deploy the Pipeline or Workflow, you are prompted to select a User Group:

You cannot pass in a value for this templated setting from another Workflow.

Ensure that the User Groups you select have Action: read, Permission Type: Deployments, and Application: the current Application or All Applications.

Enter the time duration that Harness should wait for the approval or rejection before killing the deployment process. You can use w  for week, d  for day, h  for hour, m  for minutes, s  for seconds and ms for milliseconds. For example, 1d for one day.

The maximum is 3w 3d 20h 30m.

Select Execute in Parallel with Previous Step checkbox to execute the steps in parallel.

Click Advanced Settings to set the additional settings.

Select either Do not skipSkip always, or Skip Based on Assertion Expression for setting the skip option. For more information, see Pipeline Skip Conditions.

Click Add Variable. These variables serve as inputs to later stages of the same Pipeline, where they support conditional execution or user overrides. See Pipeline Skip Conditions and Using Variables in Workflow Approvals.

Click Submit.

Deploy the Pipeline. When you deploy your Pipeline, the Approval Stage notifies the selected User Group(s), via their configured notification settings to approve or reject the deployment.

In Deployments page, the Approval Stage displays the following information:

  • Started At: The time at which the Pipeline was triggered.
  • Time Remaining: Time remaining to complete the Pipeline deployment.
  • Approval User Groups: The user group(s) that you have specified to notify for the approval requests.
  • Timeout: The time duration that Harness should wait for the approval or rejection before killing the deployment process.
    The maximum timeout duration is 24 days.
  • Will Expire At: The time at which the Pipeline will expire.
  • Triggered By: The user who triggered the Pipeline deployment. It can be triggered using a Pipeline or Trigger process.
  • Variables: Details of the variable inputs that you have specified for the conditional execution of later Pipeline stages. For more information, see Skip Based on Assertion Expression.
    You can also Approve, Reject, or Approve/Reject with a note the Pipeline deployment from this page.

Needs Approval:

Approved Pipeline:

How did we do?