Skip to main content

Approvals tutorial

This tutorial demonstrates how to use approvals by using a Harness CD pipeline as an example.

To follow along with this tutorial, you need:

You can specify Harness User Group(s) to approve or reject a Pipeline at any point in its execution. During deployment, the User Group members use Harness Manager to approve or reject the Pipeline deployment manually.

Approvals can be added in between Stages to prevent the Pipeline execution from proceeding without an approval.

Add an Approval stage

  1. In the visual view of the pipeline, select Add Stage, and then select Approval as the stage type.

  2. Name the stage manual-approval-stage, and select Harness Approval as the approval type.

  3. Select the Approval step to open the Manual Approval pane. The Manual Approval pane includes predefined values for Name, Timeout, and Approval Message. You need to add the User Group you created under Approvers. You can also add Approver Inputs under this step.

  4. Select Apply Changes. Your approval step is created.

  5. Save the changes to the pipeline.

  6. Since you already have a deploy stage present before the approval stage, drag the deploy stage to the right of the approval stage.

  7. Verify and confirm the approval stage and deploy stage as shown below.

  8. Select Save, and then select Run to run the pipeline.

  9. As an approver, you'll receive notification on the Console Log pane under the Logs once the pipeline is running to approve or reject the pipeline. Click on Approve to run the pipeline.