The deploy step encountered an error: The process '/usr/bin/git' failed with exit code 1 ❌
Rollczi opened this issue · 3 comments
Rollczi commented
Describe the bug
Creating worktree…
/usr/bin/git fetch --no-recurse-submodules --depth=1 origin master
From https://github.com/Rollczi/LiteCommands
* branch master -> FETCH_HEAD
* [new branch] master -> origin/master
/usr/bin/git worktree add --no-checkout --detach github-pages-deploy-action-temp-deployment-folder
Preparing worktree (detached HEAD 2cedce4)
/usr/bin/git checkout -B master origin/master
Switched to and reset branch 'master'
branch 'master' set up to track 'origin/master'.
/usr/bin/chmod -R +rw /home/runner/work/LiteCommands/LiteCommands
/usr/bin/rsync -q -av --checksum --progress /home/runner/work/LiteCommands/LiteCommands/. github-pages-deploy-action-temp-deployment-folder --delete --exclude CNAME --exclude .nojekyll --exclude .ssh --exclude .git --exclude .github --exclude github-pages-deploy-action-temp-deployment-folder
Checking if there are files to commit…
/usr/bin/git add --all .
/usr/bin/git checkout -b github-pages-deploy-action/n2xxarv10
Switched to a new branch 'github-pages-deploy-action/n2xxarv10'
/usr/bin/git commit -m Update Sponsors in README.md --quiet --no-verify
Force-pushing changes...
/usr/bin/git push --force ***github.com/Rollczi/LiteCommands.git github-pages-deploy-action/n2xxarv10:master
remote: error: GH006: Protected branch update failed for refs/heads/master.
remote: error: Commits must have verified signatures. Changes must be made through a pull request.
To https://github.com/Rollczi/LiteCommands.git
! [remote rejected] github-pages-deploy-action/n2xxarv10 -> master (protected branch hook declined)
error: failed to push some refs to 'https://github.com/Rollczi/LiteCommands.git'
Running post deployment cleanup jobs… 🗑️
/usr/bin/git checkout -B github-pages-deploy-action/n2xxarv10
Reset branch 'github-pages-deploy-action/n2xxarv10'
/usr/bin/chmod -R +rw 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 1 ❌
Notice: Deployment failed! ❌
##[debug]Node Action run completed with exit code 1
##[debug]deployment_status='failed'
##[debug]Set output deployment-status = failed
##[debug]Finishing: Deploy 🚀
Workflow
name: Update Sponsors
on:
workflow_dispatch:
schedule:
- cron: 30 15 * * *
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎️
uses: actions/checkout@v2
with:
lfs: true
- name: Generate Sponsors 💖
uses: JamesIves/github-sponsors-readme-action@v1
with:
token: ${{ secrets.PAT }}
file: 'README.md'
template: <a href="https://github.com/{{{ login }}}"><img src="https://images.weserv.nl/?url=https://github.com/{{{ login }}}.png?v=4&mask=circle" width="60px" alt="{{{ name }}}" /></a>
- name: Deploy 🚀
uses: JamesIves/github-pages-deploy-action@v4
with:
commit-message: Update Sponsors in README.md
branch: master
folder: '.'
Additional Comments
JamesIves commented
You have a protected branch rule:
remote: error: GH006: Protected branch update failed for refs/heads/master.
remote: error: Commits must have verified signatures. Changes must be made through a pull request.
To https://github.com/Rollczi/LiteCommands.git
! [remote rejected] github-pages-deploy-action/n2xxarv10 -> master (protected branch hook declined)
You'd need to provide a personal access token from your user account with permissions to override that rule for that to work.
Rollczi commented
You have a protected branch rule:
remote: error: GH006: Protected branch update failed for refs/heads/master. remote: error: Commits must have verified signatures. Changes must be made through a pull request. To https://github.com/Rollczi/LiteCommands.git ! [remote rejected] github-pages-deploy-action/n2xxarv10 -> master (protected branch hook declined)
You'd need to provide a personal access token from your user account with permissions to override that rule for that to work.
I added all permissions and nothing changed
JamesIves commented
I would suggest removing the branch protection rule for pull requests in that case unless you absolutely need it.