update release number #20
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
push: | |
tags: | |
- 'v*' | |
jobs: | |
release: | |
name: Publish Release | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout sources | |
uses: actions/checkout@v3 | |
- name: Setup Node.js 17 | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 17 | |
- name: Install jsonnet, jsonnet-bundler and grafana/plugin-validator | |
run: | | |
go install github.com/google/go-jsonnet/cmd/jsonnet@latest | |
go install github.com/jsonnet-bundler/jsonnet-bundler/cmd/jb@latest | |
go install github.com/grafana/plugin-validator/pkg/cmd/plugincheck2@latest | |
echo "$HOME/go/bin" >> $GITHUB_PATH | |
- name: Install dependencies | |
run: make deps | |
- name: Test & Build plugin | |
run: | | |
make test-backend | |
make build # also runs frontend tests | |
- name: Check if package version and git tag matches | |
run: | | |
if [ "v$(jq -r '.info.version' dist/plugin.json)" != "${GITHUB_REF#refs/*/}" ]; then | |
echo "Plugin version doesn't match git tag" | |
exit 1 | |
fi | |
- name: Sign plugin | |
run: make sign | |
env: | |
GRAFANA_API_KEY: ${{ secrets.GRAFANA_API_KEY }} | |
- name: Create plugin zip file | |
run: make zip | |
- name: Run plugincheck | |
run: make plugincheck | |
- name: Create GitHub release | |
run: ci/scripts/github-release.sh | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |