Skip to content

Commit 213e0e5

Browse files
committed
Added GitHub token configuration to the build workflow for Antora, enabling secure access to the repository during the build process.
1 parent 9e8b9be commit 213e0e5

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

.github/workflows/build-and-deploy.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ concurrency:
1717
jobs:
1818
build:
1919
runs-on: ubuntu-latest
20+
env:
21+
ANTORA_GITHUB_TOKEN: ${{ secrets.ANTORA_GITHUB_TOKEN }}
2022
steps:
2123
- name: Checkout repository
2224
uses: actions/checkout@v5
@@ -49,6 +51,9 @@ jobs:
4951
working-directory: ./site
5052
run: pnpm install
5153

54+
- name: Configure git to use the token for GitHub
55+
run: git config --global url."https://${ANTORA_GITHUB_TOKEN}@github.com/".insteadOf "https://github.com/"
56+
5257
- name: Build Antora site
5358
working-directory: ./site
5459
run: pnpm exec antora --stacktrace antora-playbook.yml

0 commit comments

Comments
 (0)