diff --git a/release.yaml b/release.yaml index 5df363a3b51..3d7b1132dcb 100644 --- a/release.yaml +++ b/release.yaml @@ -51,6 +51,32 @@ internal: echo "Build created, see:" echo $body | jq .web_url fi + minor: + - name: 'buildkite' + cmd: | + echo "Triggering build on sourcegraph/sourcegraph with VERSION={{version}} on branch {{git.branch}}" + body=$(wget --content-on-error -O- --header="Content-Type: application/json" --header="Authorization: Bearer $BUILDKITE_ACCESS_TOKEN" --post-data '{ + "commit": "HEAD", + "branch": "{{git.branch}}", + "message": "Internal release build for {{version}}", + "env": { + "RELEASE_INTERNAL": "true", + "VERSION": "{{tag}}", + "IS_DEVELOPMENT_RELEASE": "{{is_development}}" + } + }' https://api.buildkite.com/v2/organizations/sourcegraph/pipelines/sourcegraph/builds) + exit_code=$? + + if [ $exit_code != 0 ]; then + echo "❌ Failed to create build on Buildkite, got:" + echo "--- raw body ---" + echo $body + echo "--- raw body ---" + exit $exit_code + else + echo "Build created, see:" + echo $body | jq .web_url + fi finalize: steps: - name: 'Register on release registry'