docker / bake-action

GitHub Action to use Docker Buildx Bake as a high-level build command
https://github.com/marketplace/actions/docker-buildx-bake
Apache License 2.0
186 stars 29 forks source link

Github App tokens for remote contexts and private repos #242

Closed jackweinbender closed 2 months ago

jackweinbender commented 2 months ago

Description

I see in the docs that this action provides a means to pass along a PAT to the bake command so that the action is able to pull remote repositories. I've been able to successfully use this functionality, but I really don't want to have to use a PAT.

For other similar actions, my org uses https://github.com/actions/create-github-app-token to generate tokens that allow Actions from one repo to pull from other repos in our org. We do this to avoid using PATs, since they are tied to individual users, yadda, yadda, yadda.

When I've tried passing this token along, using the GIT_AUTH_TOKEN or BUILDX_BAKE_GIT_AUTH_TOKEN environment variables (which I use successfully with my PAT), the request fails with a 403.

I don't know how/why this wouldn't work, but I don't exactly know how bake works with this kind of auth.

jackweinbender commented 2 months ago

Closing this—it was not a problem with the action