From 1f36e377e2f4ff7c65f995577d1e999841aee4a9 Mon Sep 17 00:00:00 2001 From: Dominik Prokop Date: Tue, 3 Nov 2020 18:34:45 +0100 Subject: [PATCH] Adds storybook integrity check to drone config (#28785) * Adds storybook integrity check to dron config * Update starlark files * Review comments * Bump grabpl version * Drone: Fix dangling dependency Signed-off-by: Arve Knudsen Co-authored-by: Arve Knudsen --- .drone.yml | 42 +++++++++++-------- .../scripts/deploy.sh | 2 +- .../grafana-plugin-ci-e2e/scripts/deploy.sh | 2 +- .../grafana-plugin-ci/scripts/deploy.sh | 2 +- scripts/lib.star | 3 +- 5 files changed, 29 insertions(+), 22 deletions(-) diff --git a/.drone.yml b/.drone.yml index 633eb30c2cb..a0502caece5 100644 --- a/.drone.yml +++ b/.drone.yml @@ -17,7 +17,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - curl -fLO https://github.com/jwilder/dockerize/releases/download/v$${DOCKERIZE_VERSION}/dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz - tar -C bin -xzvf dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz @@ -141,6 +141,7 @@ steps: image: grafana/build-container:1.2.28 commands: - yarn storybook:build + - ./bin/grabpl verify-storybook environment: NODE_OPTIONS: --max_old_space_size=4096 depends_on: @@ -251,7 +252,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - curl -fLO https://github.com/jwilder/dockerize/releases/download/v$${DOCKERIZE_VERSION}/dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz - tar -C bin -xzvf dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz @@ -412,6 +413,7 @@ steps: image: grafana/build-container:1.2.28 commands: - yarn storybook:build + - ./bin/grabpl verify-storybook environment: NODE_OPTIONS: --max_old_space_size=4096 depends_on: @@ -584,7 +586,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - name: build-windows-installer image: grafana/ci-wix:0.1.1 @@ -633,7 +635,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl environment: DOCKERIZE_VERSION: 0.6.1 @@ -708,7 +710,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - ./bin/grabpl verify-version ${DRONE_TAG} - curl -fLO https://github.com/jwilder/dockerize/releases/download/v$${DOCKERIZE_VERSION}/dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz @@ -850,6 +852,7 @@ steps: image: grafana/build-container:1.2.28 commands: - yarn storybook:build + - ./bin/grabpl verify-storybook environment: NODE_OPTIONS: --max_old_space_size=4096 depends_on: @@ -1004,7 +1007,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - name: build-windows-installer image: grafana/ci-wix:0.1.1 @@ -1054,7 +1057,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - git clone "https://$${GITHUB_TOKEN}@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise @@ -1337,7 +1340,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - git clone "https://$$env:GITHUB_TOKEN@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise - git checkout ${DRONE_TAG} @@ -1402,7 +1405,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - ./bin/grabpl verify-version ${DRONE_TAG} environment: @@ -1479,7 +1482,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - ./bin/grabpl verify-version v7.3.0-test - curl -fLO https://github.com/jwilder/dockerize/releases/download/v$${DOCKERIZE_VERSION}/dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz @@ -1621,6 +1624,7 @@ steps: image: grafana/build-container:1.2.28 commands: - yarn storybook:build + - ./bin/grabpl verify-storybook environment: NODE_OPTIONS: --max_old_space_size=4096 depends_on: @@ -1765,7 +1769,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - name: build-windows-installer image: grafana/ci-wix:0.1.1 @@ -1815,7 +1819,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - git clone "https://$${GITHUB_TOKEN}@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise @@ -2092,7 +2096,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - git clone "https://$$env:GITHUB_TOKEN@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise - git checkout master @@ -2157,7 +2161,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - ./bin/grabpl verify-version v7.3.0-test environment: @@ -2243,7 +2247,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - curl -fLO https://github.com/jwilder/dockerize/releases/download/v$${DOCKERIZE_VERSION}/dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz - tar -C bin -xzvf dockerize-linux-amd64-v$${DOCKERIZE_VERSION}.tar.gz @@ -2381,6 +2385,7 @@ steps: image: grafana/build-container:1.2.28 commands: - yarn storybook:build + - ./bin/grabpl verify-storybook environment: NODE_OPTIONS: --max_old_space_size=4096 depends_on: @@ -2483,7 +2488,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - name: build-windows-installer image: grafana/ci-wix:0.1.1 @@ -2529,7 +2534,7 @@ steps: image: grafana/build-container:1.2.28 commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl - chmod +x bin/grabpl - git clone "https://$${GITHUB_TOKEN}@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise @@ -2685,6 +2690,7 @@ steps: image: grafana/build-container:1.2.28 commands: - yarn storybook:build + - ./bin/grabpl verify-storybook environment: NODE_OPTIONS: --max_old_space_size=4096 depends_on: @@ -2790,7 +2796,7 @@ steps: image: grafana/ci-wix:0.1.1 commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/windows/grabpl.exe -OutFile grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/windows/grabpl.exe -OutFile grabpl.exe - git clone "https://$$env:GITHUB_TOKEN@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise - git checkout $$env:DRONE_BRANCH diff --git a/packages/grafana-toolkit/docker/grafana-plugin-ci-alpine/scripts/deploy.sh b/packages/grafana-toolkit/docker/grafana-plugin-ci-alpine/scripts/deploy.sh index 143736951bb..1265cff4c4b 100755 --- a/packages/grafana-toolkit/docker/grafana-plugin-ci-alpine/scripts/deploy.sh +++ b/packages/grafana-toolkit/docker/grafana-plugin-ci-alpine/scripts/deploy.sh @@ -43,7 +43,7 @@ get_file "https://codeclimate.com/downloads/test-reporter/test-reporter-latest-l "b4138199aa755ebfe171b57cc46910b13258ace5fbc4eaa099c42607cd0bff32" chmod +x /usr/local/bin/cc-test-reporter -curl -fL -o /usr/local/bin/grabpl "https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl" +curl -fL -o /usr/local/bin/grabpl "https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl" apk add --no-cache git # Install Mage diff --git a/packages/grafana-toolkit/docker/grafana-plugin-ci-e2e/scripts/deploy.sh b/packages/grafana-toolkit/docker/grafana-plugin-ci-e2e/scripts/deploy.sh index 5512ba5c7cc..1fd6ccb7abe 100755 --- a/packages/grafana-toolkit/docker/grafana-plugin-ci-e2e/scripts/deploy.sh +++ b/packages/grafana-toolkit/docker/grafana-plugin-ci-e2e/scripts/deploy.sh @@ -44,7 +44,7 @@ get_file "https://codeclimate.com/downloads/test-reporter/test-reporter-latest-l "b4138199aa755ebfe171b57cc46910b13258ace5fbc4eaa099c42607cd0bff32" chmod 755 /usr/local/bin/cc-test-reporter -wget -O /usr/local/bin/grabpl "https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl" +wget -O /usr/local/bin/grabpl "https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl" chmod +x /usr/local/bin/grabpl # Install Mage diff --git a/packages/grafana-toolkit/docker/grafana-plugin-ci/scripts/deploy.sh b/packages/grafana-toolkit/docker/grafana-plugin-ci/scripts/deploy.sh index 9d465737db6..a794da750ec 100755 --- a/packages/grafana-toolkit/docker/grafana-plugin-ci/scripts/deploy.sh +++ b/packages/grafana-toolkit/docker/grafana-plugin-ci/scripts/deploy.sh @@ -27,7 +27,7 @@ get_file "https://codeclimate.com/downloads/test-reporter/test-reporter-latest-l "b4138199aa755ebfe171b57cc46910b13258ace5fbc4eaa099c42607cd0bff32" chmod +x /usr/local/bin/cc-test-reporter -wget -O /usr/local/bin/grabpl "https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.23/grabpl" +wget -O /usr/local/bin/grabpl "https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v0.5.24/grabpl" chmod +x /usr/local/bin/grabpl # Install Mage diff --git a/scripts/lib.star b/scripts/lib.star index 71619981904..10878432a36 100644 --- a/scripts/lib.star +++ b/scripts/lib.star @@ -1,4 +1,4 @@ -grabpl_version = '0.5.23' +grabpl_version = '0.5.24' build_image = 'grafana/build-container:1.2.28' publish_image = 'grafana/grafana-ci-deploy:1.2.6' grafana_docker_image = 'grafana/drone-grafana-docker:0.3.2' @@ -269,6 +269,7 @@ def build_storybook_step(edition, ver_mode): }, 'commands': [ 'yarn storybook:build', + './bin/grabpl verify-storybook', ], }