Skip to content

Commit 5655bd5

Browse files
committed
Switch deploy workflows to built-in GITHUB_TOKEN
1 parent 4b418d7 commit 5655bd5

2 files changed

Lines changed: 8 additions & 4 deletions

File tree

.github/workflows/deploy-beta.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ on:
88
jobs:
99
build-and-deploy:
1010
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
1113

1214
steps:
1315
- name: Checkout repository
@@ -26,7 +28,7 @@ jobs:
2628

2729
- name: Deploy with gh-pages (to /beta folder)
2830
run: |
29-
git remote set-url origin https://git:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git
31+
git remote set-url origin https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git
3032
npm run deploy -- --dest beta -u "github-actions-bot <support+actions@github.com>"
3133
env:
32-
GITHUB_TOKEN: ${{ secrets.ACTIONS_DEPLOY_KEY }}
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/deploy.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ on:
88
jobs:
99
build-and-deploy:
1010
runs-on: ubuntu-latest
11+
permissions:
12+
contents: write
1113

1214
steps:
1315
- name: Checkout repository
@@ -26,7 +28,7 @@ jobs:
2628

2729
- name: Deploy with gh-pages
2830
run: |
29-
git remote set-url origin https://git:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git
31+
git remote set-url origin https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git
3032
npm run deploy -- -u "github-actions-bot <support+actions@github.com>"
3133
env:
32-
GITHUB_TOKEN: ${{ secrets.ACTIONS_DEPLOY_KEY }}
34+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)