Ephemeral instances: fetch the grafana version from the package.json file (#88300)

This commit is contained in:
Bruno 2024-05-28 11:52:00 -03:00 committed by GitHub
parent 8418aca823
commit 07debd66c2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 16 additions and 2 deletions

View File

@ -57,11 +57,18 @@ jobs:
ref: main
path: ephemeral
- name: Get latest grafana version number
run: |
# if package.json contains e.g. 11.0.0-pre, this writes 11.0.0 to version.txt
curl https://raw.githubusercontent.com/grafana/grafana/main/package.json | jq -r .version | grep -o '^[0-9\.]*' > version.txt
- name: Run action
env:
GITHUB_EVENT: ${{ toJson(github.event)}}
run: |
GRAFANA_VERSION=10.1.0
# Create a prerelease version number using the latest version from the package.json in the grafana repo.
export GRAFANA_VERSION="$(cat version.txt)"
echo "${GRAFANA_VERSION}"
cd $GITHUB_WORKSPACE/ephemeral/src
go run . \

View File

@ -49,11 +49,18 @@ jobs:
ref: main
path: ephemeral
- name: Get latest grafana version number
run: |
# if package.json contains e.g. 11.0.0-pre, this writes 11.0.0 to version.txt
curl https://raw.githubusercontent.com/grafana/grafana/main/package.json | jq -r .version | grep -o '^[0-9\.]*' > version.txt
- name: Run action
env:
GITHUB_EVENT: ${{ toJson(github.event)}}
run: |
GRAFANA_VERSION=10.1.0
# Create a prerelease version number using the latest version from the package.json in the grafana repo.
export GRAFANA_VERSION="$(cat version.txt)"
echo "${GRAFANA_VERSION}"
cd $GITHUB_WORKSPACE/ephemeral/src
go run . \