Skip to content

Commit

Permalink
[fix] GitHub NPM authorization of Docker building
Browse files Browse the repository at this point in the history
  • Loading branch information
TechQuery committed Aug 15, 2024
1 parent 40a2980 commit 989d993
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ on:
jobs:
docker:
runs-on: ubuntu-latest

permissions:
packages: read
steps:
- uses: actions/checkout@v4

Expand Down Expand Up @@ -42,8 +43,14 @@ jobs:

- name: Inject Environment variables
run: |
cat >> .npmrc <<EOF
//npm.pkg.github.com/:_authToken=${{ secrets.NPM_TOKEN }}
@kaiyuanshe:registry=https://npm.pkg.github.com
always-auth=true
EOF
cat > .env.local <<EOF
${{ secrets.ENV_FILE }}
VERCEL_URL=hackathon.kaiyuanshe.cn
EOF
- name: Build and Push image
uses: docker/build-push-action@v3
Expand Down

1 comment on commit 989d993

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deploy preview for open-hackathon ready!

✅ Preview
https://open-hackathon-rsfiwiyt0-techquerys-projects.vercel.app

Built with commit 989d993.
This pull request is being automatically deployed with vercel-action

Please sign in to comment.