Unlock the staging area when the habitat/build pipeline completes
There is no "complete" event, but we want to unlock the staging area
anytime our build pipeline passes, fails, or is canceled.
@@ -118,12 +118,24 @@ subscriptions:
post_commit: true
only_if_modified:
- components/chef-ui-library/*
- # If a build in the habitat/build pipeline fails, unlock the staging area
+ # When the habitat/build pipeline fails, unlock the staging area
- workload: buildkite_build_failed:{{agent_id}}:habitat/build:*
actions:
- unlock_staging_area:post_merge:
post_commit: true
always_run: true
+ # When the habitat/build pipeline completes successfully, unlock the staging area
+ - workload: buildkite_build_passed:{{agent_id}}:habitat/build:*
+ actions:
+ - unlock_staging_area:post_merge:
+ post_commit: true
+ always_run: true
+ # When the habitat/build pipeline is canceled, unlock the staging area
+ - workload: buildkite_build_canceled:{{agent_id}}:habitat/build:*
+ actions:
+ - unlock_staging_area:post_merge:
+ post_commit: true
+ always_run: true
# These actions are taken, in order they are specified, after the Habitat packages are successfully built
- workload: buildkite_hab_build_group_published:{{agent_id}}:*
actions:
@@ -136,9 +148,6 @@ subscriptions:
post_commit: true
- bash:.expeditor/purge-cdn.sh:
post_commit: true
- - unlock_staging_area:post_merge:
- post_commit: true
- always_run: true
# Update our compliance-profile pinnings when new profiles are released
- workload: hab_package_published:unstable:chef/automate-compliance-profiles/*
actions:
