Open
Description
I'm trying to switch from tibdex/github-app-token@v1
to actions/create-github-app-token@v1
and a token created for a github app fails to check out a repository after the change.
I created a workflow that demonstrates the problem. You'll need to update the app as well as the repo checked out. Checkout tibdex
succeeds whereas Checkout gha
fails.
Can't tell what the difference is in the tokens.
name: wtf
on:
push:
branches-ignore:
- main
- develop
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
jobs:
token-madness:
runs-on: ubuntu-latest
env:
APP_ID: ${{ vars.MY_APP_APP_ID }}
PEM: ${{ secrets.MY_APP_APP_PEM }}
steps:
- name: Generate tibdex token
id: tibdex
uses: tibdex/github-app-token@v1
with:
app_id: ${{ env.APP_ID }}
private_key: ${{ env.PEM }}
- name: Generate actions token
id: gha
uses: actions/create-github-app-token@v1
with:
app-id: ${{ env.APP_ID }}
private-key: ${{ env.PEM }}
- name: who am i gha?
run: gh auth status
env:
GH_TOKEN: ${{ steps.gha.outputs.token }}
- name: who am i tibdex?
run: gh auth status
env:
GH_TOKEN: ${{ steps.tibdex.outputs.token }}
- name: Checkout gha
uses: actions/checkout@v4
with:
repository: testing/foobar
token: ${{ steps.gha.outputs.token }}
- name: Checkout tibdex
uses: actions/checkout@v4
with:
repository: testing/foobar
token: ${{ steps.tibdex.outputs.token }}
Metadata
Metadata
Assignees
Labels
No labels