mirror of
https://github.com/grafana/grafana.git
synced 2025-01-02 12:17:01 -06:00
CircleCI: Fix test release pipeline (#24701)
* CircleCI: Fix test release pipeline * CircleCI: Ensure that we don't release NPM packages when testing
This commit is contained in:
parent
7fcf2615e1
commit
bd42407620
@ -15,7 +15,9 @@ aliases:
|
||||
tags:
|
||||
ignore: /^v[0-9]+(\.[0-9]+){2}(-.+|[^-.]*)$/
|
||||
branches:
|
||||
ignore: master
|
||||
ignore:
|
||||
- master
|
||||
- chore/test-release-pipeline
|
||||
- &filter-only-master
|
||||
branches:
|
||||
only: master
|
||||
@ -91,7 +93,7 @@ jobs:
|
||||
elif [[ $CIRCLE_BRANCH == "chore/test-release-pipeline" ]]; then
|
||||
# We're testing the release pipeline
|
||||
/tmp/grabpl build-backend --edition << parameters.edition >> \
|
||||
--variants << parameters.variant >> v6.7.0-beta1
|
||||
--variants << parameters.variant >> v7.0.0-test
|
||||
else
|
||||
# A master or PR build
|
||||
/tmp/grabpl build-backend --edition << parameters.edition >> \
|
||||
@ -405,7 +407,7 @@ jobs:
|
||||
/tmp/grabpl package --jobs 2 --edition oss --sign $CIRCLE_TAG
|
||||
elif [[ $CIRCLE_BRANCH == "chore/test-release-pipeline" ]]; then
|
||||
# We're testing the release pipeline
|
||||
/tmp/grabpl package --jobs 2 --edition oss --sign v6.7.0-beta1
|
||||
/tmp/grabpl package --jobs 2 --edition oss --sign v7.0.0-test
|
||||
elif [[ $CIRCLE_BRANCH == "master" ]]; then
|
||||
# A master build
|
||||
/tmp/grabpl package --jobs 2 --edition oss --sign --build-id $CIRCLE_WORKFLOW_ID
|
||||
@ -467,7 +469,7 @@ jobs:
|
||||
/tmp/grabpl package --jobs 2 --edition enterprise --sign $CIRCLE_TAG
|
||||
elif [[ $CIRCLE_BRANCH == "chore/test-release-pipeline" ]]; then
|
||||
# We're testing the release pipeline
|
||||
/tmp/grabpl package --jobs 2 --edition enterprise --sign v6.7.0-beta1
|
||||
/tmp/grabpl package --jobs 2 --edition enterprise --sign v7.0.0-test
|
||||
elif [[ $CIRCLE_BRANCH == "master" ]]; then
|
||||
# A master build
|
||||
/tmp/grabpl package --jobs 2 --edition enterprise --sign --build-id $CIRCLE_WORKFLOW_ID
|
||||
@ -610,6 +612,14 @@ jobs:
|
||||
# This version is necessary for building cross-platform images
|
||||
version: 18.09.3
|
||||
- install-grabpl
|
||||
- run:
|
||||
name: Install gcloud SDK
|
||||
command: |
|
||||
echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | \
|
||||
sudo tee -a /etc/apt/sources.list.d/google-cloud-sdk.list
|
||||
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | \
|
||||
sudo apt-key --keyring /usr/share/keyrings/cloud.google.gpg add -
|
||||
sudo apt-get update && sudo apt-get install google-cloud-sdk
|
||||
# XXX: Is this necessary?
|
||||
- run: docker run --privileged linuxkit/binfmt:v0.6
|
||||
- run:
|
||||
@ -932,6 +942,14 @@ jobs:
|
||||
- run:
|
||||
name: npm - Prepare auth token
|
||||
command: "echo //registry.npmjs.org/:_authToken=$NPM_TOKEN >> ~/.npmrc"
|
||||
- run:
|
||||
name: Exit if release pipeline test
|
||||
command: |
|
||||
if [[ $CIRCLE_BRANCH == "chore/test-release-pipeline" ]]; then
|
||||
# We're testing the release pipeline
|
||||
echo "We're testing the release pipeline, so stopping before publishing"
|
||||
circleci step halt
|
||||
fi
|
||||
- run:
|
||||
name: Release packages
|
||||
command: ./scripts/build/release-packages.sh "${CIRCLE_TAG}"
|
||||
|
Loading…
Reference in New Issue
Block a user