Skip to content

Commit 4caae50

Browse files
authored
Update GitHub Pages deployment workflow
Added user information for GitHub Actions deployment.
1 parent d671600 commit 4caae50

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

.github/workflows/deploy.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Deploy to GitHub Pages (with PAT)
1+
name: Deploy to GitHub Pages
22

33
on:
44
push:
@@ -7,10 +7,16 @@ on:
77

88
permissions:
99
contents: write
10+
pages: write
11+
id-token: write
12+
deployments: write
1013

1114
jobs:
1215
build-deploy:
1316
runs-on: ubuntu-latest
17+
environment:
18+
name: github-pages
19+
url: https://azurecosmosdb.github.io/gallery/
1420
steps:
1521
# Checkout source repo
1622
- uses: actions/checkout@v4
@@ -31,10 +37,12 @@ jobs:
3137
- name: Build website
3238
run: yarn build
3339

34-
# Deploy using PAT to gh-pages branch
40+
# Deploy to gh-pages branch using PAT
3541
- name: Deploy to GitHub Pages
3642
uses: peaceiris/actions-gh-pages@v3
3743
with:
3844
personal_token: ${{ secrets.GH_PAT }}
3945
publish_dir: ./build
40-
publish_branch: gh-pages
46+
publish_branch: gh-pages
47+
user_name: 'github-actions[bot]'
48+
user_email: 'github-actions[bot]@users.noreply.github.com'

0 commit comments

Comments
 (0)