Revert "Update ephemeral instances workflow to get version from package.json" (#85347)

Revert "Update ephemeral instances workflow to get version from package.json …"

This reverts commit dda1531952.
This commit is contained in:
Leonor Oliveira
2024-03-28 12:56:48 +00:00
committed by GitHub
parent fe802f6d88
commit 29c76b98d4
2 changed files with 6 additions and 11 deletions

4
.github/CODEOWNERS vendored
View File

@@ -688,8 +688,8 @@ embed.go @grafana/grafana-as-code
/.github/workflows/publish-kinds-release.yml @grafana/platform-cat /.github/workflows/publish-kinds-release.yml @grafana/platform-cat
/.github/workflows/verify-kinds.yml @grafana/platform-cat /.github/workflows/verify-kinds.yml @grafana/platform-cat
/.github/workflows/dashboards-issue-add-label.yml @grafana/dashboards-squad /.github/workflows/dashboards-issue-add-label.yml @grafana/dashboards-squad
/.github/workflows/ephemeral-instances-pr-comment.yml @grafana/grafana-backend-services-squad /.github/workflows/ephemeral-instances-pr-comment.yml @grafana/grafana-operator-experience-squad
/.github/workflows/ephemeral-instances-pr-opened-closed.yml @grafana/grafana-backend-services-squad /.github/workflows/ephemeral-instances-pr-opened-closed.yml @grafana/grafana-operator-experience-squad
/.github/workflows/create-security-patch-from-security-mirror.yml @grafana/grafana-release-guild /.github/workflows/create-security-patch-from-security-mirror.yml @grafana/grafana-release-guild
/.github/workflows/core-plugins-build-and-release.yml @grafana/plugins-platform-frontend @grafana/plugins-platform-backend /.github/workflows/core-plugins-build-and-release.yml @grafana/plugins-platform-frontend @grafana/plugins-platform-backend
/.github/workflows/i18n-crowdin-upload.yml @grafana/grafana-frontend-platform /.github/workflows/i18n-crowdin-upload.yml @grafana/grafana-frontend-platform

View File

@@ -56,18 +56,13 @@ jobs:
token: ${{ steps.generate_token.outputs.token }} token: ${{ steps.generate_token.outputs.token }}
ref: main ref: main
path: ephemeral 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 - name: Run action
env: env:
GITHUB_EVENT: ${{ toJson(github.event)}} GITHUB_EVENT: ${{ toJson(github.event)}}
run: | run: |
# Create a prerelease version number using the latest version from package.json and some metadata from the github event. GRAFANA_VERSION=10.1.0
v=$(cat version.txt)
export GRAFANA_VERSION="$v-ephemeral-${{ github.event.issue.number}}-${{ github.run_number }}-${{ github.run_attempt }}"
echo "${GRAFANA_VERSION}"
cd $GITHUB_WORKSPACE/ephemeral/src cd $GITHUB_WORKSPACE/ephemeral/src
go run . \ go run . \
-GITHUB_TOKEN="${{ steps.generate_token.outputs.token }}" \ -GITHUB_TOKEN="${{ steps.generate_token.outputs.token }}" \
@@ -75,7 +70,7 @@ jobs:
-GITHUB_TRIGGERING_ACTOR="${{ github.triggering_actor }}" \ -GITHUB_TRIGGERING_ACTOR="${{ github.triggering_actor }}" \
-GCOM_HOST="${{ secrets.EI_GCOM_HOST }}" \ -GCOM_HOST="${{ secrets.EI_GCOM_HOST }}" \
-GCOM_TOKEN="${{ secrets.EI_GCOM_TOKEN }}" \ -GCOM_TOKEN="${{ secrets.EI_GCOM_TOKEN }}" \
-HOSTED_GRAFANA_IMAGE_TAG="$GRAFANA_VERSION" \ -HOSTED_GRAFANA_IMAGE_TAG="$GRAFANA_VERSION-ephemeral-oss-${{ github.event.issue.number}}-${{ github.run_number }}-${{ github.run_attempt }}" \
-REGISTRY="${{ secrets.EI_EPHEMERAL_INSTANCES_REGISTRY }}" \ -REGISTRY="${{ secrets.EI_EPHEMERAL_INSTANCES_REGISTRY }}" \
-GRAFANA_VERSION="$GRAFANA_VERSION" \ -GRAFANA_VERSION="$GRAFANA_VERSION" \
-GCP_SERVICE_ACCOUNT_KEY_BASE64="${{ secrets.EI_GCP_SERVICE_ACCOUNT_KEY_BASE64 }}" \ -GCP_SERVICE_ACCOUNT_KEY_BASE64="${{ secrets.EI_GCP_SERVICE_ACCOUNT_KEY_BASE64 }}" \