Skip to main content

Rollback pipelines

You can add a Rollback Pipeline failure strategy to your pipelines. Rollback pipeline applies to all steps and stages in a pipeline.

info

If a pipeline includes a child pipeline as a stage (Pipeline chaining), rolling back the parent pipeline will not roll back the child pipeline as the latter is considered as a separate execution. In such cases, only the deployment stages of the parent pipeline roll back.

Currently, the Rollback Pipeline failure strategy applies to the following deployments only:

  • Kubernetes
  • Native Helm
  • Amazon Elastic Container Service (ECS)

Rollback pipeline steps or stages

  1. In a pipeline's step or stage, select Advanced.

  2. In Failure Strategy > On failure of type, select a failure type or select All Errors. Go to Step and Stage Failure Strategy Settings for information about error types.

  3. In Perform Action, select Rollback Pipeline.

    Here's the equivalent YAML for the Pipeline Rollback failure strategy:

    failureStrategies:
    - onFailure:
    errors:
    - AllErrors
    action:
    type: PipelineRollback

During pipeline execution, in Permissible Actions, if you select Mark as Fail, the pipeline stage fails and rolls back.

If you select Mark as Success, the stage passes, and the next stage's execution begins.

See also

Step and stage failure strategy references