diff --git a/.github/workflows/sync-next.yml b/.github/workflows/sync-next.yml index de01012fb..1f1b97842 100644 --- a/.github/workflows/sync-next.yml +++ b/.github/workflows/sync-next.yml @@ -6,9 +6,6 @@ on: # 00:00 Israel Time (UTC+3, IDT) - cron: '0 21 * * *' -permissions: - contents: write - jobs: sync: name: Sync @@ -19,6 +16,10 @@ jobs: with: ref: next fetch-depth: 0 + + # We're using a deploy key here to be able to override the the branch protection rules. + # Force push is only allowed for admins, and the default `GITHUB_TOKEN` doesn't have admin + # permissions, and it can't be added to the bypass list, while a deploy key can. ssh-key: ${{ secrets.DEPLOY_KEY }} persist-credentials: false