diff --git a/.drone.yml b/.drone.yml index 95800b080660..1e119503a8fc 100644 --- a/.drone.yml +++ b/.drone.yml @@ -11,7 +11,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -113,7 +113,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -129,15 +129,13 @@ steps: name: initialize - commands: - ./bin/grabpl build-backend --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --variants linux-x64,linux-x64-musl,osx64,win64,armv6 --no-pull-enterprise depends_on: - initialize environment: {} image: grafana/build-container:1.5.3 name: build-backend - commands: - - ./bin/grabpl build-frontend --jobs 8 --no-install-deps --edition oss --build-id - ${DRONE_BUILD_NUMBER} --no-pull-enterprise + - ./bin/grabpl build-frontend --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} depends_on: - initialize environment: @@ -146,7 +144,6 @@ steps: name: build-frontend - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: @@ -189,7 +186,7 @@ steps: name: ensure-cuetsified - commands: - . scripts/build/gpg-test-vars.sh && ./bin/grabpl package --jobs 8 --edition oss - --build-id ${DRONE_BUILD_NUMBER} --no-pull-enterprise --variants linux-x64,linux-x64-musl,osx64,win64,armv6 + --build-id ${DRONE_BUILD_NUMBER} depends_on: - build-plugins - build-backend @@ -333,7 +330,7 @@ services: steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -407,7 +404,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -445,7 +442,6 @@ steps: name: lint-docs - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: @@ -491,7 +487,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -529,7 +525,6 @@ steps: name: lint-docs - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: @@ -572,7 +567,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -672,7 +667,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -699,15 +694,13 @@ steps: from_secret: drone_token - commands: - ./bin/grabpl build-backend --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: {} image: grafana/build-container:1.5.3 name: build-backend - commands: - - ./bin/grabpl build-frontend --jobs 8 --no-install-deps --edition oss --build-id - ${DRONE_BUILD_NUMBER} --no-pull-enterprise + - ./bin/grabpl build-frontend --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} depends_on: - initialize environment: @@ -716,7 +709,6 @@ steps: name: build-frontend - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: @@ -760,8 +752,7 @@ steps: image: grafana/build-container:1.5.3 name: ensure-cuetsified - commands: - - ./bin/grabpl package --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} --no-pull-enterprise - --sign + - ./bin/grabpl package --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} --sign depends_on: - build-plugins - build-backend @@ -1031,7 +1022,7 @@ services: steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -1109,7 +1100,7 @@ steps: name: identify-runner - commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/windows/grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/windows/grabpl.exe -OutFile grabpl.exe image: grafana/ci-wix:0.1.1 name: initialize @@ -1164,7 +1155,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -1246,7 +1237,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -1263,7 +1254,7 @@ steps: name: initialize - commands: - ./bin/grabpl build-backend --jobs 8 --edition oss --github-token $${GITHUB_TOKEN} - --no-pull-enterprise ${DRONE_TAG} + ${DRONE_TAG} depends_on: - initialize environment: @@ -1272,8 +1263,8 @@ steps: image: grafana/build-container:1.5.3 name: build-backend - commands: - - ./bin/grabpl build-frontend --jobs 8 --github-token $${GITHUB_TOKEN} --no-install-deps - --edition oss --no-pull-enterprise ${DRONE_TAG} + - ./bin/grabpl build-frontend --jobs 8 --github-token $${GITHUB_TOKEN} --edition + oss ${DRONE_TAG} depends_on: - initialize environment: @@ -1282,7 +1273,7 @@ steps: name: build-frontend - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --github-token $${GITHUB_TOKEN} - --edition oss --no-pull-enterprise ${DRONE_TAG} + --edition oss ${DRONE_TAG} depends_on: - initialize environment: @@ -1326,8 +1317,8 @@ steps: image: grafana/build-container:1.5.3 name: ensure-cuetsified - commands: - - ./bin/grabpl package --jobs 8 --edition oss --github-token $${GITHUB_TOKEN} --no-pull-enterprise - --sign ${DRONE_TAG} + - ./bin/grabpl package --jobs 8 --edition oss --github-token $${GITHUB_TOKEN} --sign + ${DRONE_TAG} depends_on: - build-plugins - build-backend @@ -1530,7 +1521,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -1650,7 +1641,7 @@ services: steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -1734,7 +1725,7 @@ steps: name: identify-runner - commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/windows/grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/windows/grabpl.exe -OutFile grabpl.exe image: grafana/ci-wix:0.1.1 name: initialize @@ -1793,7 +1784,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -1832,7 +1823,7 @@ steps: name: initialize - commands: - ./bin/grabpl build-backend --jobs 8 --edition enterprise --github-token $${GITHUB_TOKEN} - --no-pull-enterprise ${DRONE_TAG} + ${DRONE_TAG} depends_on: - initialize environment: @@ -1841,8 +1832,8 @@ steps: image: grafana/build-container:1.5.3 name: build-backend - commands: - - ./bin/grabpl build-frontend --jobs 8 --github-token $${GITHUB_TOKEN} --no-install-deps - --edition enterprise --no-pull-enterprise ${DRONE_TAG} + - ./bin/grabpl build-frontend --jobs 8 --github-token $${GITHUB_TOKEN} --edition + enterprise ${DRONE_TAG} depends_on: - initialize environment: @@ -1851,7 +1842,7 @@ steps: name: build-frontend - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --github-token $${GITHUB_TOKEN} - --edition enterprise --no-pull-enterprise ${DRONE_TAG} + --edition enterprise ${DRONE_TAG} depends_on: - initialize environment: @@ -1897,7 +1888,7 @@ steps: name: ensure-cuetsified - commands: - ./bin/grabpl build-backend --jobs 8 --edition enterprise2 --github-token $${GITHUB_TOKEN} - --no-pull-enterprise ${DRONE_TAG} + ${DRONE_TAG} depends_on: - initialize environment: @@ -1907,7 +1898,7 @@ steps: name: build-backend-enterprise2 - commands: - ./bin/grabpl package --jobs 8 --edition enterprise --github-token $${GITHUB_TOKEN} - --no-pull-enterprise --sign ${DRONE_TAG} + --sign ${DRONE_TAG} depends_on: - build-plugins - build-backend @@ -2033,7 +2024,7 @@ steps: name: upload-packages - commands: - ./bin/grabpl package --jobs 8 --edition enterprise2 --github-token $${GITHUB_TOKEN} - --no-pull-enterprise --sign ${DRONE_TAG} + --sign ${DRONE_TAG} depends_on: - build-plugins - build-backend @@ -2113,7 +2104,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2285,7 +2276,7 @@ services: steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2413,7 +2404,7 @@ steps: name: identify-runner - commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/windows/grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/windows/grabpl.exe -OutFile grabpl.exe - git clone "https://$$env:GITHUB_TOKEN@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise @@ -2488,7 +2479,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2566,7 +2557,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2627,7 +2618,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2706,7 +2697,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2768,7 +2759,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2804,7 +2795,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2851,7 +2842,7 @@ steps: name: initialize - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2899,7 +2890,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2962,7 +2953,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -2978,15 +2969,13 @@ steps: name: initialize - commands: - ./bin/grabpl build-backend --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: {} image: grafana/build-container:1.5.3 name: build-backend - commands: - - ./bin/grabpl build-frontend --jobs 8 --no-install-deps --edition oss --build-id - ${DRONE_BUILD_NUMBER} --no-pull-enterprise + - ./bin/grabpl build-frontend --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} depends_on: - initialize environment: @@ -2995,7 +2984,6 @@ steps: name: build-frontend - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: @@ -3039,8 +3027,7 @@ steps: image: grafana/build-container:1.5.3 name: ensure-cuetsified - commands: - - ./bin/grabpl package --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} --no-pull-enterprise - --sign + - ./bin/grabpl package --jobs 8 --edition oss --build-id ${DRONE_BUILD_NUMBER} --sign depends_on: - build-plugins - build-backend @@ -3201,7 +3188,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -3314,7 +3301,7 @@ services: steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -3391,7 +3378,7 @@ steps: name: identify-runner - commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/windows/grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/windows/grabpl.exe -OutFile grabpl.exe image: grafana/ci-wix:0.1.1 name: initialize @@ -3439,7 +3426,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -3474,15 +3461,13 @@ steps: name: initialize - commands: - ./bin/grabpl build-backend --jobs 8 --edition enterprise --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise depends_on: - initialize environment: {} image: grafana/build-container:1.5.3 name: build-backend - commands: - - ./bin/grabpl build-frontend --jobs 8 --no-install-deps --edition enterprise --build-id - ${DRONE_BUILD_NUMBER} --no-pull-enterprise + - ./bin/grabpl build-frontend --jobs 8 --edition enterprise --build-id ${DRONE_BUILD_NUMBER} depends_on: - initialize environment: @@ -3491,7 +3476,7 @@ steps: name: build-frontend - commands: - ./bin/grabpl build-frontend-packages --jobs 8 --edition enterprise --build-id - ${DRONE_BUILD_NUMBER} --no-pull-enterprise + ${DRONE_BUILD_NUMBER} depends_on: - initialize environment: @@ -3537,7 +3522,7 @@ steps: name: ensure-cuetsified - commands: - ./bin/grabpl build-backend --jobs 8 --edition enterprise2 --build-id ${DRONE_BUILD_NUMBER} - --variants linux-x64 --no-pull-enterprise + --variants linux-x64 depends_on: - initialize environment: {} @@ -3545,7 +3530,7 @@ steps: name: build-backend-enterprise2 - commands: - ./bin/grabpl package --jobs 8 --edition enterprise --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise --sign + --sign depends_on: - build-plugins - build-backend @@ -3680,7 +3665,7 @@ steps: name: upload-packages - commands: - ./bin/grabpl package --jobs 8 --edition enterprise2 --build-id ${DRONE_BUILD_NUMBER} - --no-pull-enterprise --variants linux-x64 --sign + --variants linux-x64 --sign depends_on: - build-plugins - build-backend @@ -3753,7 +3738,7 @@ services: [] steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -3915,7 +3900,7 @@ services: steps: - commands: - mkdir -p bin - - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/grabpl + - curl -fL -o bin/grabpl https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/grabpl - chmod +x bin/grabpl image: byrnedo/alpine-curl:0.1.8 name: grabpl @@ -4033,7 +4018,7 @@ steps: name: identify-runner - commands: - $$ProgressPreference = "SilentlyContinue" - - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.7/windows/grabpl.exe + - Invoke-WebRequest https://grafana-downloads.storage.googleapis.com/grafana-build-pipeline/v2.9.50/windows/grabpl.exe -OutFile grabpl.exe - git clone "https://$$env:GITHUB_TOKEN@github.com/grafana/grafana-enterprise.git" - cd grafana-enterprise @@ -4145,6 +4130,6 @@ kind: secret name: prerelease_bucket --- kind: signature -hmac: 7ad7687ab8c91a3f765fa2137b62fc9be62173705760402a485735895173c33c +hmac: 269c5ba0967ad88138b1346e45f3905ccb99d1c437f3e0afd014d0802b0f1f10 ... diff --git a/.github/workflows/bump-version.yml b/.github/workflows/bump-version.yml index e1d30961ff6b..150851ea8f94 100644 --- a/.github/workflows/bump-version.yml +++ b/.github/workflows/bump-version.yml @@ -35,12 +35,6 @@ jobs: echo "::set-output name=branch_name::v${{steps.regex-match.outputs.group1}}" echo "::set-output name=branch_exist::$(git ls-remote --heads https://github.com/grafana/grafana.git v${{ steps.regex-match.outputs.group1 }}.x | wc -l)" - - name: Check input version is aligned with branch(not main) - if: steps.intermedia.outputs.branch_exist != '0' && !contains(steps.intermedia.outputs.short_ref, steps.intermedia.outputs.branch_name) - run: | - echo " You need to run the workflow on branch v${{steps.regex-match.outputs.group1}}.x - exit 1 - - name: Check input version is aligned with branch(main) if: steps.intermedia.outputs.branch_exist == '0' && !contains(steps.intermedia.outputs.short_ref, 'main') run: | diff --git a/lerna.json b/lerna.json index cf2158934d35..8757d5a82fcd 100644 --- a/lerna.json +++ b/lerna.json @@ -4,5 +4,5 @@ "packages": [ "packages/*" ], - "version": "8.3.7" + "version": "8.3.10" } diff --git a/package.json b/package.json index 96d3b57f90ae..9c69f4f083ea 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "license": "AGPL-3.0-only", "private": true, "name": "grafana", - "version": "8.3.7", + "version": "8.3.10", "repository": "github:grafana/grafana", "scripts": { "api-tests": "jest --notify --watch --config=devenv/e2e-api-tests/jest.js", diff --git a/packages/grafana-data/package.json b/packages/grafana-data/package.json index c47440f3b7e4..e94f048489db 100644 --- a/packages/grafana-data/package.json +++ b/packages/grafana-data/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/data", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana Data Library", "keywords": [ "typescript" @@ -22,7 +22,7 @@ }, "dependencies": { "@braintree/sanitize-url": "5.0.2", - "@grafana/schema": "8.3.7", + "@grafana/schema": "8.3.10", "@types/d3-interpolate": "^1.4.0", "d3-interpolate": "1.4.0", "date-fns": "2.21.3", diff --git a/packages/grafana-e2e-selectors/package.json b/packages/grafana-e2e-selectors/package.json index 577e56804065..710daefad61e 100644 --- a/packages/grafana-e2e-selectors/package.json +++ b/packages/grafana-e2e-selectors/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/e2e-selectors", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana End-to-End Test Selectors Library", "keywords": [ "cli", diff --git a/packages/grafana-e2e/package.json b/packages/grafana-e2e/package.json index 446a77d87649..b4a3d1f75ed0 100644 --- a/packages/grafana-e2e/package.json +++ b/packages/grafana-e2e/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/e2e", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana End-to-End Test Library", "keywords": [ "cli", @@ -49,7 +49,7 @@ "@babel/core": "7.14.6", "@babel/preset-env": "7.14.7", "@cypress/webpack-preprocessor": "5.9.1", - "@grafana/e2e-selectors": "8.3.7", + "@grafana/e2e-selectors": "8.3.10", "@grafana/tsconfig": "^1.0.0-rc1", "@mochajs/json-file-reporter": "^1.2.0", "babel-loader": "8.2.2", diff --git a/packages/grafana-runtime/package.json b/packages/grafana-runtime/package.json index 90e0696c1662..5d6659ef48bb 100644 --- a/packages/grafana-runtime/package.json +++ b/packages/grafana-runtime/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/runtime", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana Runtime Library", "keywords": [ "grafana", @@ -23,9 +23,9 @@ }, "dependencies": { "@emotion/css": "11.1.3", - "@grafana/data": "8.3.7", - "@grafana/e2e-selectors": "8.3.7", - "@grafana/ui": "8.3.7", + "@grafana/data": "8.3.10", + "@grafana/e2e-selectors": "8.3.10", + "@grafana/ui": "8.3.10", "@sentry/browser": "5.25.0", "history": "4.10.1", "lodash": "4.17.21", diff --git a/packages/grafana-schema/package.json b/packages/grafana-schema/package.json index fe8e653bad05..dc307a2a63cd 100644 --- a/packages/grafana-schema/package.json +++ b/packages/grafana-schema/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/schema", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana Schema Library", "keywords": [ "typescript" diff --git a/packages/grafana-toolkit/package.json b/packages/grafana-toolkit/package.json index 88bf8dfe8ac6..d157f7494385 100644 --- a/packages/grafana-toolkit/package.json +++ b/packages/grafana-toolkit/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/toolkit", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana Toolkit", "keywords": [ "grafana", @@ -28,10 +28,10 @@ "dependencies": { "@babel/core": "7.13.14", "@babel/preset-env": "7.13.12", - "@grafana/data": "8.3.7", + "@grafana/data": "8.3.10", "@grafana/eslint-config": "2.5.1", "@grafana/tsconfig": "^1.0.0-rc1", - "@grafana/ui": "8.3.7", + "@grafana/ui": "8.3.10", "@jest/core": "26.6.3", "@rushstack/eslint-patch": "1.0.6", "@types/command-exists": "^1.2.0", diff --git a/packages/grafana-ui/package.json b/packages/grafana-ui/package.json index 1fc7f5162974..ed9f81113350 100644 --- a/packages/grafana-ui/package.json +++ b/packages/grafana-ui/package.json @@ -2,7 +2,7 @@ "author": "Grafana Labs", "license": "Apache-2.0", "name": "@grafana/ui", - "version": "8.3.7", + "version": "8.3.10", "description": "Grafana Components Library", "keywords": [ "grafana", @@ -33,9 +33,9 @@ "@emotion/css": "11.1.3", "@emotion/react": "11.1.5", "@grafana/aws-sdk": "0.0.3", - "@grafana/data": "8.3.7", - "@grafana/e2e-selectors": "8.3.7", - "@grafana/schema": "8.3.7", + "@grafana/data": "8.3.10", + "@grafana/e2e-selectors": "8.3.10", + "@grafana/schema": "8.3.10", "@grafana/slate-react": "0.22.10-grafana", "@monaco-editor/react": "4.2.2", "@popperjs/core": "2.5.4", diff --git a/packages/jaeger-ui-components/package.json b/packages/jaeger-ui-components/package.json index d8caa59eea5c..391e047a59a5 100644 --- a/packages/jaeger-ui-components/package.json +++ b/packages/jaeger-ui-components/package.json @@ -1,6 +1,6 @@ { "name": "@jaegertracing/jaeger-ui-components", - "version": "8.3.7", + "version": "8.3.10", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -30,8 +30,8 @@ "dependencies": { "@emotion/css": "11.1.3", "@emotion/react": "11.1.5", - "@grafana/data": "8.3.7", - "@grafana/ui": "8.3.7", + "@grafana/data": "8.3.10", + "@grafana/ui": "8.3.10", "chance": "^1.0.10", "classnames": "^2.2.5", "combokeys": "^3.0.0", diff --git a/pkg/api/ldap_debug.go b/pkg/api/ldap_debug.go index bba65c70257a..aff5ef20b78e 100644 --- a/pkg/api/ldap_debug.go +++ b/pkg/api/ldap_debug.go @@ -217,6 +217,11 @@ func (hs *HTTPServer) PostSyncUserWithLDAP(c *models.ReqContext) response.Respon ReqContext: c, ExternalUser: user, SignupAllowed: hs.Cfg.LDAPAllowSignup, + UserLookupParams: models.UserLookupParams{ + UserID: &query.Result.Id, // Upsert by ID only + Email: nil, + Login: nil, + }, } err = bus.Dispatch(upsertCmd) diff --git a/pkg/api/login_oauth.go b/pkg/api/login_oauth.go index 436d8878e21b..d35e797d6945 100644 --- a/pkg/api/login_oauth.go +++ b/pkg/api/login_oauth.go @@ -310,6 +310,11 @@ func syncUser( ReqContext: ctx, ExternalUser: extUser, SignupAllowed: connect.IsSignupAllowed(), + UserLookupParams: models.UserLookupParams{ + Email: &extUser.Email, + UserID: nil, + Login: nil, + }, } if err := bus.Dispatch(cmd); err != nil { return nil, err diff --git a/pkg/login/ldap_login.go b/pkg/login/ldap_login.go index 0cf5e6d8c7af..93398841e964 100644 --- a/pkg/login/ldap_login.go +++ b/pkg/login/ldap_login.go @@ -57,9 +57,13 @@ var loginUsingLDAP = func(ctx context.Context, query *models.LoginUserQuery) (bo ReqContext: query.ReqContext, ExternalUser: externalUser, SignupAllowed: setting.LDAPAllowSignup, + UserLookupParams: models.UserLookupParams{ + Login: &externalUser.Login, + Email: &externalUser.Email, + UserID: nil, + }, } - err = bus.DispatchCtx(ctx, upsert) - if err != nil { + if err = bus.DispatchCtx(ctx, upsert); err != nil { return true, err } query.User = upsert.Result diff --git a/pkg/models/user_auth.go b/pkg/models/user_auth.go index 6a96ccb6bad2..2f670031b360 100644 --- a/pkg/models/user_auth.go +++ b/pkg/models/user_auth.go @@ -54,11 +54,11 @@ type RequestURIKey struct{} // COMMANDS type UpsertUserCommand struct { - ReqContext *ReqContext - ExternalUser *ExternalUserInfo + ReqContext *ReqContext + ExternalUser *ExternalUserInfo + UserLookupParams + Result *User SignupAllowed bool - - Result *User } type SetAuthInfoCommand struct { @@ -95,9 +95,14 @@ type LoginUserQuery struct { type GetUserByAuthInfoQuery struct { AuthModule string AuthId string - UserId int64 - Email string - Login string + UserLookupParams +} + +type UserLookupParams struct { + // Describes lookup order as well + UserID *int64 // if set, will try to find the user by id + Email *string // if set, will try to find the user by email + Login *string // if set, will try to find the user by login } type GetExternalUserInfoByLoginQuery struct { diff --git a/pkg/services/contexthandler/authproxy/authproxy.go b/pkg/services/contexthandler/authproxy/authproxy.go index adc99ce7eb64..f6642fce037c 100644 --- a/pkg/services/contexthandler/authproxy/authproxy.go +++ b/pkg/services/contexthandler/authproxy/authproxy.go @@ -247,6 +247,11 @@ func (auth *AuthProxy) LoginViaLDAP() (int64, error) { ReqContext: auth.ctx, SignupAllowed: auth.cfg.LDAPAllowSignup, ExternalUser: extUser, + UserLookupParams: models.UserLookupParams{ + Login: &extUser.Login, + Email: &extUser.Email, + UserID: nil, + }, } if err := bus.Dispatch(upsert); err != nil { return 0, err @@ -303,6 +308,11 @@ func (auth *AuthProxy) LoginViaHeader() (int64, error) { ReqContext: auth.ctx, SignupAllowed: auth.cfg.AuthProxyAutoSignUp, ExternalUser: extUser, + UserLookupParams: models.UserLookupParams{ + UserID: nil, + Login: &extUser.Login, + Email: &extUser.Email, + }, } err := bus.Dispatch(upsert) diff --git a/pkg/services/login/authinfoservice/service.go b/pkg/services/login/authinfoservice/service.go index 096dd7968324..ac64fc2ea336 100644 --- a/pkg/services/login/authinfoservice/service.go +++ b/pkg/services/login/authinfoservice/service.go @@ -85,11 +85,12 @@ func (s *Implementation) LookupAndFix(query *models.GetUserByAuthInfoQuery) (boo } // if user id was specified and doesn't match the user_auth entry, remove it - if query.UserId != 0 && query.UserId != authQuery.Result.UserId { - err := s.DeleteAuthInfo(&models.DeleteAuthInfoCommand{ + if query.UserLookupParams.UserID != nil && + *query.UserLookupParams.UserID != 0 && + *query.UserLookupParams.UserID != authQuery.Result.UserId { + if err := s.DeleteAuthInfo(&models.DeleteAuthInfoCommand{ UserAuth: authQuery.Result, - }) - if err != nil { + }); err != nil { s.logger.Error("Error removing user_auth entry", "error", err) } @@ -120,42 +121,42 @@ func (s *Implementation) LookupAndFix(query *models.GetUserByAuthInfoQuery) (boo return false, nil, nil, models.ErrUserNotFound } -func (s *Implementation) LookupByOneOf(userId int64, email string, login string) (bool, *models.User, error) { - foundUser := false +func (s *Implementation) LookupByOneOf(params *models.UserLookupParams) (*models.User, error) { var user *models.User var err error + foundUser := false // If not found, try to find the user by id - if userId != 0 { - foundUser, user, err = s.getUserById(userId) + if params.UserID != nil && *params.UserID != 0 { + foundUser, user, err = s.getUserById(*params.UserID) if err != nil { - return false, nil, err + return nil, err } } // If not found, try to find the user by email address - if !foundUser && email != "" { - user = &models.User{Email: email} + if !foundUser && params.Email != nil && *params.Email != "" { + user = &models.User{Email: *params.Email} foundUser, err = s.getUser(user) if err != nil { - return false, nil, err + return nil, err } } // If not found, try to find the user by login - if !foundUser && login != "" { - user = &models.User{Login: login} + if !foundUser && params.Login != nil && *params.Login != "" { + user = &models.User{Login: *params.Login} foundUser, err = s.getUser(user) if err != nil { - return false, nil, err + return nil, err } } if !foundUser { - return false, nil, models.ErrUserNotFound + return nil, models.ErrUserNotFound } - return foundUser, user, nil + return user, nil } func (s *Implementation) GenericOAuthLookup(authModule string, authId string, userID int64) (*models.UserAuth, error) { @@ -184,7 +185,7 @@ func (s *Implementation) LookupAndUpdate(query *models.GetUserByAuthInfoQuery) ( // 2. FindByUserDetails if !foundUser { - _, user, err = s.LookupByOneOf(query.UserId, query.Email, query.Login) + user, err = s.LookupByOneOf(&query.UserLookupParams) if err != nil { return nil, err } diff --git a/pkg/services/login/authinfoservice/user_auth_test.go b/pkg/services/login/authinfoservice/user_auth_test.go index bba765b3fb90..880a964a2198 100644 --- a/pkg/services/login/authinfoservice/user_auth_test.go +++ b/pkg/services/login/authinfoservice/user_auth_test.go @@ -39,7 +39,7 @@ func TestUserAuth(t *testing.T) { // By Login login := "loginuser0" - query := &models.GetUserByAuthInfoQuery{Login: login} + query := &models.GetUserByAuthInfoQuery{UserLookupParams: models.UserLookupParams{Login: &login}} user, err := srv.LookupAndUpdate(query) require.Nil(t, err) @@ -48,7 +48,9 @@ func TestUserAuth(t *testing.T) { // By ID id := user.Id - _, user, err = srv.LookupByOneOf(id, "", "") + user, err = srv.LookupByOneOf(&models.UserLookupParams{ + UserID: &id, + }) require.Nil(t, err) require.Equal(t, user.Id, id) @@ -56,7 +58,9 @@ func TestUserAuth(t *testing.T) { // By Email email := "user1@test.com" - _, user, err = srv.LookupByOneOf(0, email, "") + user, err = srv.LookupByOneOf(&models.UserLookupParams{ + Email: &email, + }) require.Nil(t, err) require.Equal(t, user.Email, email) @@ -64,7 +68,9 @@ func TestUserAuth(t *testing.T) { // Don't find nonexistent user email = "nonexistent@test.com" - _, user, err = srv.LookupByOneOf(0, email, "") + user, err = srv.LookupByOneOf(&models.UserLookupParams{ + Email: &email, + }) require.Equal(t, models.ErrUserNotFound, err) require.Nil(t, user) @@ -81,7 +87,7 @@ func TestUserAuth(t *testing.T) { // create user_auth entry login := "loginuser0" - query.Login = login + query.UserLookupParams.Login = &login user, err = srv.LookupAndUpdate(query) require.Nil(t, err) @@ -95,9 +101,9 @@ func TestUserAuth(t *testing.T) { require.Equal(t, user.Login, login) // get with non-matching id - id := user.Id + idPlusOne := user.Id + 1 - query.UserId = id + 1 + query.UserLookupParams.UserID = &idPlusOne user, err = srv.LookupAndUpdate(query) require.Nil(t, err) @@ -138,7 +144,9 @@ func TestUserAuth(t *testing.T) { login := "loginuser0" // Calling GetUserByAuthInfoQuery on an existing user will populate an entry in the user_auth table - query := &models.GetUserByAuthInfoQuery{Login: login, AuthModule: "test", AuthId: "test"} + query := &models.GetUserByAuthInfoQuery{AuthModule: "test", AuthId: "test", UserLookupParams: models.UserLookupParams{ + Login: &login, + }} user, err := srv.LookupAndUpdate(query) require.Nil(t, err) @@ -186,7 +194,9 @@ func TestUserAuth(t *testing.T) { // Calling srv.LookupAndUpdateQuery on an existing user will populate an entry in the user_auth table // Make the first log-in during the past getTime = func() time.Time { return time.Now().AddDate(0, 0, -2) } - query := &models.GetUserByAuthInfoQuery{Login: login, AuthModule: "test1", AuthId: "test1"} + query := &models.GetUserByAuthInfoQuery{AuthModule: "test1", AuthId: "test1", UserLookupParams: models.UserLookupParams{ + Login: &login, + }} user, err := srv.LookupAndUpdate(query) getTime = time.Now @@ -196,7 +206,9 @@ func TestUserAuth(t *testing.T) { // Add a second auth module for this user // Have this module's last log-in be more recent getTime = func() time.Time { return time.Now().AddDate(0, 0, -1) } - query = &models.GetUserByAuthInfoQuery{Login: login, AuthModule: "test2", AuthId: "test2"} + query = &models.GetUserByAuthInfoQuery{AuthModule: "test2", AuthId: "test2", UserLookupParams: models.UserLookupParams{ + Login: &login, + }} user, err = srv.LookupAndUpdate(query) getTime = time.Now @@ -236,16 +248,21 @@ func TestUserAuth(t *testing.T) { // Expect to pass since there's a matching login user getTime = func() time.Time { return time.Now().AddDate(0, 0, -2) } - query := &models.GetUserByAuthInfoQuery{Login: login, AuthModule: genericOAuthModule, AuthId: ""} + query := &models.GetUserByAuthInfoQuery{AuthModule: genericOAuthModule, AuthId: "", UserLookupParams: models.UserLookupParams{ + Login: &login, + }} user, err := srv.LookupAndUpdate(query) getTime = time.Now require.Nil(t, err) require.Equal(t, user.Login, login) + otherLoginUser := "aloginuser" // Should throw a "user not found" error since there's no matching login user getTime = func() time.Time { return time.Now().AddDate(0, 0, -2) } - query = &models.GetUserByAuthInfoQuery{Login: "aloginuser", AuthModule: genericOAuthModule, AuthId: ""} + query = &models.GetUserByAuthInfoQuery{AuthModule: genericOAuthModule, AuthId: "", UserLookupParams: models.UserLookupParams{ + Login: &otherLoginUser, + }} user, err = srv.LookupAndUpdate(query) getTime = time.Now diff --git a/pkg/services/login/loginservice/loginservice.go b/pkg/services/login/loginservice/loginservice.go index 4b05a81d6e74..41aecd1e3092 100644 --- a/pkg/services/login/loginservice/loginservice.go +++ b/pkg/services/login/loginservice/loginservice.go @@ -45,11 +45,9 @@ func (ls *Implementation) UpsertUser(cmd *models.UpsertUserCommand) error { extUser := cmd.ExternalUser user, err := ls.AuthInfoService.LookupAndUpdate(&models.GetUserByAuthInfoQuery{ - AuthModule: extUser.AuthModule, - AuthId: extUser.AuthId, - UserId: extUser.UserId, - Email: extUser.Email, - Login: extUser.Login, + AuthModule: extUser.AuthModule, + AuthId: extUser.AuthId, + UserLookupParams: cmd.UserLookupParams, }) if err != nil { if !errors.Is(err, models.ErrUserNotFound) { diff --git a/pkg/services/login/loginservice/loginservice_test.go b/pkg/services/login/loginservice/loginservice_test.go index 573aebe1cbac..bde2f74461f0 100644 --- a/pkg/services/login/loginservice/loginservice_test.go +++ b/pkg/services/login/loginservice/loginservice_test.go @@ -94,10 +94,12 @@ func Test_teamSync(t *testing.T) { AuthInfoService: authInfoMock, } - upserCmd := &models.UpsertUserCommand{ExternalUser: &models.ExternalUserInfo{Email: "test_user@example.org"}} + email := "test_user@example.org" + upserCmd := &models.UpsertUserCommand{ExternalUser: &models.ExternalUserInfo{Email: email}, + UserLookupParams: models.UserLookupParams{Email: &email}} expectedUser := &models.User{ Id: 1, - Email: "test_user@example.org", + Email: email, Name: "test_user", Login: "test_user", } diff --git a/plugins-bundled/internal/input-datasource/package.json b/plugins-bundled/internal/input-datasource/package.json index 80ff95104c83..eeec39687c20 100644 --- a/plugins-bundled/internal/input-datasource/package.json +++ b/plugins-bundled/internal/input-datasource/package.json @@ -1,6 +1,6 @@ { "name": "@grafana-plugins/input-datasource", - "version": "8.3.7", + "version": "8.3.10", "description": "Input Datasource", "private": true, "repository": { @@ -24,9 +24,9 @@ "webpack": "5.58.1" }, "dependencies": { - "@grafana/data": "8.3.7", - "@grafana/toolkit": "8.3.7", - "@grafana/ui": "8.3.7", + "@grafana/data": "8.3.10", + "@grafana/toolkit": "8.3.10", + "@grafana/ui": "8.3.10", "jquery": "3.5.1", "react": "17.0.1", "react-dom": "17.0.1", diff --git a/public/app/features/alerting/unified/components/rules/RuleDetailsActionButtons.tsx b/public/app/features/alerting/unified/components/rules/RuleDetailsActionButtons.tsx index 1d7aea696270..59bd5b96399d 100644 --- a/public/app/features/alerting/unified/components/rules/RuleDetailsActionButtons.tsx +++ b/public/app/features/alerting/unified/components/rules/RuleDetailsActionButtons.tsx @@ -2,7 +2,7 @@ import React, { FC, Fragment, useState } from 'react'; import { useDispatch } from 'react-redux'; import { useLocation } from 'react-router-dom'; import { css } from '@emotion/css'; -import { AppEvents, GrafanaTheme2, urlUtil } from '@grafana/data'; +import { AppEvents, GrafanaTheme2, textUtil, urlUtil } from '@grafana/data'; import { config } from '@grafana/runtime'; import { Button, ConfirmModal, ClipboardButton, HorizontalGroup, LinkButton, useStyles2 } from '@grafana/ui'; import { contextSrv } from 'app/core/services/context_srv'; @@ -91,7 +91,7 @@ export const RuleDetailsActionButtons: FC = ({ rule, rulesSource }) => { variant="primary" icon="book" target="__blank" - href={rule.annotations[Annotation.runbookURL]} + href={textUtil.sanitizeUrl(rule.annotations[Annotation.runbookURL])} > View runbook diff --git a/scripts/drone/pipelines/pr.star b/scripts/drone/pipelines/pr.star index d44f2dfb275e..b3dab62a9d00 100644 --- a/scripts/drone/pipelines/pr.star +++ b/scripts/drone/pipelines/pr.star @@ -54,7 +54,6 @@ ver_mode = 'pr' def pr_pipelines(edition): services = integration_test_services(edition) volumes = integration_test_services_volumes() - variants = ['linux-x64', 'linux-x64-musl', 'osx64', 'win64', 'armv6',] include_enterprise2 = edition == 'enterprise' test_steps = [ lint_drone_step(), @@ -67,7 +66,7 @@ def pr_pipelines(edition): test_frontend_step(), ] build_steps = [ - build_backend_step(edition=edition, ver_mode=ver_mode, variants=variants), + build_backend_step(edition=edition, ver_mode=ver_mode), build_frontend_step(edition=edition, ver_mode=ver_mode), build_frontend_package_step(edition=edition, ver_mode=ver_mode), build_plugins_step(edition=edition), @@ -94,7 +93,7 @@ def pr_pipelines(edition): # Insert remaining build_steps build_steps.extend([ - package_step(edition=edition, ver_mode=ver_mode, include_enterprise2=include_enterprise2, variants=variants), + package_step(edition=edition, ver_mode=ver_mode, include_enterprise2=include_enterprise2), grafana_server_step(edition=edition), e2e_tests_step('dashboards-suite', edition=edition), e2e_tests_step('smoke-tests-suite', edition=edition), diff --git a/scripts/drone/steps/lib.star b/scripts/drone/steps/lib.star index 71a868959f62..09c6be044f80 100644 --- a/scripts/drone/steps/lib.star +++ b/scripts/drone/steps/lib.star @@ -1,6 +1,6 @@ load('scripts/drone/vault.star', 'from_secret', 'github_token', 'pull_secret', 'drone_token', 'prerelease_bucket') -grabpl_version = 'v2.9.7' +grabpl_version = 'v2.9.50' build_image = 'grafana/build-container:1.5.3' publish_image = 'grafana/grafana-ci-deploy:1.3.1' deploy_docker_image = 'us.gcr.io/kubernetes-dev/drone/plugins/deploy-image' @@ -325,7 +325,7 @@ def build_backend_step(edition, ver_mode, variants=None, is_downstream=False): 'GITHUB_TOKEN': from_secret(github_token), } cmds = [ - './bin/grabpl build-backend --jobs 8 --edition {} --github-token $${{GITHUB_TOKEN}} --no-pull-enterprise ${{DRONE_TAG}}'.format( + './bin/grabpl build-backend --jobs 8 --edition {} --github-token $${{GITHUB_TOKEN}} ${{DRONE_TAG}}'.format( edition, ), ] @@ -336,7 +336,7 @@ def build_backend_step(edition, ver_mode, variants=None, is_downstream=False): build_no = '$${SOURCE_BUILD_NUMBER}' env = {} cmds = [ - './bin/grabpl build-backend --jobs 8 --edition {} --build-id {}{} --no-pull-enterprise'.format( + './bin/grabpl build-backend --jobs 8 --edition {} --build-id {}{}'.format( edition, build_no, variants_str, ), ] @@ -361,13 +361,13 @@ def build_frontend_step(edition, ver_mode, is_downstream=False): # TODO: Use percentage for num jobs if ver_mode == 'release': cmds = [ - './bin/grabpl build-frontend --jobs 8 --github-token $${GITHUB_TOKEN} --no-install-deps ' + \ - '--edition {} --no-pull-enterprise ${{DRONE_TAG}}'.format(edition), + './bin/grabpl build-frontend --jobs 8 --github-token $${GITHUB_TOKEN} ' + \ + '--edition {} ${{DRONE_TAG}}'.format(edition), ] else: cmds = [ - './bin/grabpl build-frontend --jobs 8 --no-install-deps --edition {} '.format(edition) + \ - '--build-id {} --no-pull-enterprise'.format(build_no), + './bin/grabpl build-frontend --jobs 8 --edition {} '.format(edition) + \ + '--build-id {}'.format(build_no), ] return { @@ -392,12 +392,12 @@ def build_frontend_package_step(edition, ver_mode, is_downstream=False): if ver_mode == 'release': cmds = [ './bin/grabpl build-frontend-packages --jobs 8 --github-token $${GITHUB_TOKEN} ' + \ - '--edition {} --no-pull-enterprise ${{DRONE_TAG}}'.format(edition), + '--edition {} ${{DRONE_TAG}}'.format(edition), ] else: cmds = [ './bin/grabpl build-frontend-packages --jobs 8 --edition {} '.format(edition) + \ - '--build-id {} --no-pull-enterprise'.format(build_no), + '--build-id {}'.format(build_no), ] return { @@ -625,7 +625,7 @@ def package_step(edition, ver_mode, include_enterprise2=False, variants=None, is if ver_mode == 'release': cmds = [ '{}./bin/grabpl package --jobs 8 --edition {} '.format(test_args, edition) + \ - '--github-token $${{GITHUB_TOKEN}} --no-pull-enterprise{} ${{DRONE_TAG}}'.format( + '--github-token $${{GITHUB_TOKEN}}{} ${{DRONE_TAG}}'.format( sign_args ), ] @@ -636,7 +636,7 @@ def package_step(edition, ver_mode, include_enterprise2=False, variants=None, is build_no = '$${SOURCE_BUILD_NUMBER}' cmds = [ '{}./bin/grabpl package --jobs 8 --edition {} '.format(test_args, edition) + \ - '--build-id {} --no-pull-enterprise{}{}'.format(build_no, variants_str, sign_args), + '--build-id {}{}{}'.format(build_no, variants_str, sign_args), ] return { diff --git a/yarn.lock b/yarn.lock index eb4bb2eeefd1..a38ffea093d2 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2329,9 +2329,9 @@ __metadata: version: 0.0.0-use.local resolution: "@grafana-plugins/input-datasource@workspace:plugins-bundled/internal/input-datasource" dependencies: - "@grafana/data": 8.3.7 - "@grafana/toolkit": 8.3.7 - "@grafana/ui": 8.3.7 + "@grafana/data": 8.3.10 + "@grafana/toolkit": 8.3.10 + "@grafana/ui": 8.3.10 "@types/jest": 26.0.15 "@types/lodash": 4.14.149 "@types/react": 17.0.30 @@ -2372,12 +2372,12 @@ __metadata: languageName: node linkType: hard -"@grafana/data@8.3.7, @grafana/data@workspace:*, @grafana/data@workspace:packages/grafana-data": +"@grafana/data@8.3.10, @grafana/data@workspace:*, @grafana/data@workspace:packages/grafana-data": version: 0.0.0-use.local resolution: "@grafana/data@workspace:packages/grafana-data" dependencies: "@braintree/sanitize-url": 5.0.2 - "@grafana/schema": 8.3.7 + "@grafana/schema": 8.3.10 "@grafana/tsconfig": ^1.0.0-rc1 "@rollup/plugin-commonjs": 21.0.1 "@rollup/plugin-json": 4.1.0 @@ -2432,7 +2432,7 @@ __metadata: languageName: unknown linkType: soft -"@grafana/e2e-selectors@8.3.7, @grafana/e2e-selectors@workspace:*, @grafana/e2e-selectors@workspace:packages/grafana-e2e-selectors": +"@grafana/e2e-selectors@8.3.10, @grafana/e2e-selectors@workspace:*, @grafana/e2e-selectors@workspace:packages/grafana-e2e-selectors": version: 0.0.0-use.local resolution: "@grafana/e2e-selectors@workspace:packages/grafana-e2e-selectors" dependencies: @@ -2464,7 +2464,7 @@ __metadata: "@babel/core": 7.14.6 "@babel/preset-env": 7.14.7 "@cypress/webpack-preprocessor": 5.9.1 - "@grafana/e2e-selectors": 8.3.7 + "@grafana/e2e-selectors": 8.3.10 "@grafana/tsconfig": ^1.0.0-rc1 "@mochajs/json-file-reporter": ^1.2.0 "@rollup/plugin-commonjs": 21.0.1 @@ -2522,10 +2522,10 @@ __metadata: resolution: "@grafana/runtime@workspace:packages/grafana-runtime" dependencies: "@emotion/css": 11.1.3 - "@grafana/data": 8.3.7 - "@grafana/e2e-selectors": 8.3.7 + "@grafana/data": 8.3.10 + "@grafana/e2e-selectors": 8.3.10 "@grafana/tsconfig": ^1.0.0-rc1 - "@grafana/ui": 8.3.7 + "@grafana/ui": 8.3.10 "@rollup/plugin-commonjs": 21.0.1 "@rollup/plugin-node-resolve": 13.0.6 "@sentry/browser": 5.25.0 @@ -2557,7 +2557,7 @@ __metadata: languageName: unknown linkType: soft -"@grafana/schema@8.3.7, @grafana/schema@workspace:*, @grafana/schema@workspace:packages/grafana-schema": +"@grafana/schema@8.3.10, @grafana/schema@workspace:*, @grafana/schema@workspace:packages/grafana-schema": version: 0.0.0-use.local resolution: "@grafana/schema@workspace:packages/grafana-schema" dependencies: @@ -2607,16 +2607,16 @@ __metadata: languageName: node linkType: hard -"@grafana/toolkit@8.3.7, @grafana/toolkit@workspace:*, @grafana/toolkit@workspace:packages/grafana-toolkit": +"@grafana/toolkit@8.3.10, @grafana/toolkit@workspace:*, @grafana/toolkit@workspace:packages/grafana-toolkit": version: 0.0.0-use.local resolution: "@grafana/toolkit@workspace:packages/grafana-toolkit" dependencies: "@babel/core": 7.13.14 "@babel/preset-env": 7.13.12 - "@grafana/data": 8.3.7 + "@grafana/data": 8.3.10 "@grafana/eslint-config": 2.5.1 "@grafana/tsconfig": ^1.0.0-rc1 - "@grafana/ui": 8.3.7 + "@grafana/ui": 8.3.10 "@jest/core": 26.6.3 "@rushstack/eslint-patch": 1.0.6 "@types/command-exists": ^1.2.0 @@ -2700,7 +2700,7 @@ __metadata: languageName: node linkType: hard -"@grafana/ui@8.3.7, @grafana/ui@workspace:*, @grafana/ui@workspace:packages/grafana-ui": +"@grafana/ui@8.3.10, @grafana/ui@workspace:*, @grafana/ui@workspace:packages/grafana-ui": version: 0.0.0-use.local resolution: "@grafana/ui@workspace:packages/grafana-ui" dependencies: @@ -2708,9 +2708,9 @@ __metadata: "@emotion/css": 11.1.3 "@emotion/react": 11.1.5 "@grafana/aws-sdk": 0.0.3 - "@grafana/data": 8.3.7 - "@grafana/e2e-selectors": 8.3.7 - "@grafana/schema": 8.3.7 + "@grafana/data": 8.3.10 + "@grafana/e2e-selectors": 8.3.10 + "@grafana/schema": 8.3.10 "@grafana/slate-react": 0.22.10-grafana "@grafana/tsconfig": ^1.0.0-rc1 "@mdx-js/react": 1.6.22 @@ -2923,9 +2923,9 @@ __metadata: dependencies: "@emotion/css": 11.1.3 "@emotion/react": 11.1.5 - "@grafana/data": 8.3.7 + "@grafana/data": 8.3.10 "@grafana/tsconfig": ^1.0.0-rc1 - "@grafana/ui": 8.3.7 + "@grafana/ui": 8.3.10 "@types/classnames": ^2.2.7 "@types/deep-freeze": ^0.1.1 "@types/grafana__slate-react": "npm:@types/slate-react@0.22.5"