我正在嘗試在 GitHub 頁面上部署我的 nextJS 應用程式。我在部署階段遇到錯誤。
我的node.js.yml檔案包含以下內容:
name: Node.js CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}
cache: "npm"
- run: npm ci
- run: npm run build
- run: npm run export
- run: touch ./out/.nojekyll
- name: Deploy ??
uses: JamesIves/[email protected]
with:
branch: gh-pages # The branch the action should deploy to.
folder: out # The folder the action should deploy.
在另一個分支上部署我的存盤庫時得到的錯誤代碼如下:
remote: Permission to 0xWerz/0xwerz.github.io.git denied to github-actions[bot].
fatal: unable to access 'https://github.com/0xWerz/0xwerz.github.io.git/': The requested URL returned error: 403
Running post deployment cleanup jobs… ???
/usr/bin/git checkout -B github-pages-deploy-action/tpuzb7jkb
Reset branch 'github-pages-deploy-action/tpuzb7jkb'
/usr/bin/chmod -R 777 github-pages-deploy-action-temp-deployment-folder
/usr/bin/git worktree remove github-pages-deploy-action-temp-deployment-folder --force
Error: The deploy step encountered an error: The process '/usr/bin/git' failed with exit code 128 ?
Notice: Deployment failed! ?
uj5u.com熱心網友回復:
部署操作需要對您的存盤庫的寫入權限。
或者升級到更新版本的action,即4.3.3
轉載請註明出處,本文鏈接:https://www.uj5u.com/net/468573.html
標籤:节点.js github 下一个.js github-动作 github页面
