mirror of https://github.com/grafana/grafana
[v10.4.x] CI: Sync branch and tag after release (#90209)
CI: Sync branch and tag after release (#89967)
* Added `workflow_call` event to allow other workflows to invoke the "Create or update GitHub release"
* Added `dry_run` to `github-release.yml`
* Added `latest` to `release-pr.yml` which will cause the release PR to add a `release/latest` label.
* Removed unnecessary github app creation from github-release workflow and just used permissions.
(cherry picked from commit 63e715f6a9)
pull/90268/head
parent
ffdb7d44f8
commit
1ba236b146
@ -1,27 +1,48 @@ |
||||
name: Create or update GitHub release |
||||
on: |
||||
workflow_call: |
||||
inputs: |
||||
version: |
||||
required: true |
||||
description: Needs to match, exactly, the name of a milestone (NO v prefix) |
||||
type: string |
||||
latest: |
||||
required: false |
||||
default: false |
||||
description: Mark this release as latest (`1`) or not (`0`, default) |
||||
type: string |
||||
dry_run: |
||||
required: false |
||||
default: false |
||||
type: boolean |
||||
workflow_dispatch: |
||||
inputs: |
||||
version: |
||||
required: true |
||||
description: Needs to match, exactly, the name of a milestone (NO v prefix) |
||||
type: string |
||||
latest: |
||||
required: false |
||||
description: Mark this release as latest (`1`) or not (`0`, default) |
||||
type: string |
||||
dry_run: |
||||
required: false |
||||
default: false |
||||
type: boolean |
||||
|
||||
permissions: |
||||
# contents: write allows the action(s) to create github releases |
||||
contents: write |
||||
|
||||
jobs: |
||||
main: |
||||
runs-on: ubuntu-latest |
||||
steps: |
||||
- name: "Generate token" |
||||
id: generate_token |
||||
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92 |
||||
with: |
||||
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }} |
||||
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }} |
||||
- name: Create GitHub release (manually invoked) |
||||
uses: grafana/grafana-github-actions-go/github-release@main |
||||
with: |
||||
token: ${{ steps.generate_token.outputs.token }} |
||||
token: ${{ secrets.GITHUB_TOKEN }} |
||||
version: ${{ inputs.version }} |
||||
metrics_api_key: ${{ secrets.GRAFANA_MISC_STATS_API_KEY }} |
||||
latest: ${{ inputs.latest }} |
||||
dry_run: ${{ inputs.dry_run }} |
||||
|
||||
Loading…
Reference in new issue