mirror of
https://github.com/grafana/grafana.git
synced 2024-11-26 02:40:26 -06:00
Github Actions: Fix milestone GH action (#70490)
* Remove secret from the caller action * Inherit secrets for reusable actions
This commit is contained in:
parent
c45ff94806
commit
37db29db63
6
.github/workflows/close-milestone.yml
vendored
6
.github/workflows/close-milestone.yml
vendored
@ -11,9 +11,7 @@ on:
|
||||
description: Needs to match, exactly, the name of a milestone
|
||||
required: true
|
||||
type: string
|
||||
secrets:
|
||||
token:
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
main:
|
||||
runs-on: ubuntu-latest
|
||||
@ -42,4 +40,4 @@ jobs:
|
||||
uses: ./actions/close-milestone
|
||||
with:
|
||||
version_call: ${{ inputs.version_call }}
|
||||
token: ${{ secrets.token }}
|
||||
token: ${{ steps.generate_token.outputs.token }}
|
||||
|
32
.github/workflows/milestone.yml
vendored
32
.github/workflows/milestone.yml
vendored
@ -7,27 +7,13 @@ on:
|
||||
required: true
|
||||
jobs:
|
||||
call-remove-milestone:
|
||||
- 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 }}
|
||||
- uses: grafana/grafana/.github/workflows/remove-milestone.yml@main
|
||||
with:
|
||||
version_call: ${{ github.event.inputs.version_input }}
|
||||
secrets:
|
||||
token: ${{ steps.generate_token.outputs.token }}
|
||||
uses: grafana/grafana/.github/workflows/remove-milestone.yml@main
|
||||
with:
|
||||
version_call: ${{ github.event.inputs.version_input }}
|
||||
secrets: inherit
|
||||
call-close-milestone:
|
||||
- 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 }}
|
||||
- uses: grafana/grafana/.github/workflows/close-milestone.yml@main
|
||||
with:
|
||||
version_call: ${{ github.event.inputs.version_input }}
|
||||
secrets:
|
||||
token: ${{ steps.generate_token.outputs.token }}
|
||||
needs: call-remove-milestone
|
||||
uses: grafana/grafana/.github/workflows/close-milestone.yml@main
|
||||
with:
|
||||
version_call: ${{ github.event.inputs.version_input }}
|
||||
secrets: inherit
|
||||
needs: call-remove-milestone
|
||||
|
6
.github/workflows/remove-milestone.yml
vendored
6
.github/workflows/remove-milestone.yml
vendored
@ -11,9 +11,7 @@ on:
|
||||
description: Needs to match, exactly, the name of a milestone
|
||||
required: true
|
||||
type: string
|
||||
secrets:
|
||||
token:
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
main:
|
||||
runs-on: ubuntu-latest
|
||||
@ -42,4 +40,4 @@ jobs:
|
||||
uses: ./actions/remove-milestone
|
||||
with:
|
||||
version_call: ${{ inputs.version_call }}
|
||||
token: ${{ secrets.token }}
|
||||
token: ${{ steps.generate_token.outputs.token }}
|
||||
|
Loading…
Reference in New Issue
Block a user