CI: changelog boolean type (#90948)

* bool -> boolean

* add missing type keys

* provide secrets in release-pr

* use permissions and built-in github token
This commit is contained in:
Kevin Minehart 2024-07-25 09:52:15 -05:00 committed by GitHub
parent c326d865c5
commit 14396048d7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 11 additions and 21 deletions

View File

@ -3,6 +3,7 @@ on:
workflow_call:
inputs:
version:
type: string
required: true
description: 'Target release version (semver, git tag, branch or commit)'
target:
@ -12,14 +13,15 @@ on:
dry_run:
required: false
default: false
type: bool
type: boolean
latest:
required: false
default: false
type: bool
type: boolean
workflow_dispatch:
inputs:
version:
type: string
required: true
description: 'Target release version (semver, git tag, branch or commit)'
target:
@ -29,13 +31,14 @@ on:
dry_run:
required: false
default: false
type: bool
type: boolean
latest:
required: false
default: false
type: bool
type: boolean
permissions:
contents: write
pull-requests: write
jobs:
@ -44,12 +47,6 @@ jobs:
permissions:
contents: write
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: "Checkout Grafana repo"
uses: "actions/checkout@v4"
with:
@ -69,7 +66,7 @@ jobs:
id: changelog
uses: ./.github/workflows/actions/changelog
with:
github_token: ${{ steps.generate_token.outputs.token }}
github_token: ${{ secrets.GITHUB_TOKEN }}
target: v${{ inputs.version }}
output_file: changelog_items.md
- name: "Patch CHANGELOG.md"

View File

@ -23,11 +23,11 @@ on:
dry_run:
required: false
default: false
type: bool
type: boolean
latest:
required: false
default: false
type: bool
type: boolean
permissions:
contents: write
@ -47,13 +47,6 @@ jobs:
runs-on: ubuntu-latest
if: github.repository == 'grafana/grafana'
steps:
- name: Generate bot 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: Checkout Grafana
uses: actions/checkout@v4
with:
@ -73,7 +66,7 @@ jobs:
id: changelog
uses: ./.github/workflows/actions/changelog
with:
github_token: ${{ steps.generate_token.outputs.token }}
github_token: ${{ secrets.GITHUB_TOKEN }}
target: v${{ inputs.version }}
output_file: changelog_items.md