Post-merge pipeline step

Problem to solve

We'd like to use review apps for merge-requests only. Once a merge request has been merged, we'd like to remove the review app as it is no longer necessary. There is currently no way to add a hook to run some stage after a branch has been merged.

Intended users

Developers

Further details

Benefits include reducing wasting resources through auto-shutdown of review apps when they are no longer needed.

Proposal

Example journey:

  1. Merge request is created on a branch
  2. build step succeeds
  3. the branch code is deployed to a review app (with only: -merge_requests set on this stage)
  4. The merge request is reviewed, approved, and merged
  5. Upon merge, a shutown review app stage is auto-run

Permissions and Security

Existing permissions

Documentation

What does success look like, and how can we measure that?

Links / references

Assignee Loading
Time tracking Loading