Skip to content

Commit

Permalink
revert: 'chore(IDX): replace PAT with GH App' (#2886)
Browse files Browse the repository at this point in the history
For some reason this isn't working as expected, so I need to revert
before I can look into this more.

Reverts #2863
  • Loading branch information
cgundy authored Nov 28, 2024
1 parent 8ec2ca1 commit c3ae105
Showing 1 changed file with 14 additions and 22 deletions.
36 changes: 14 additions & 22 deletions .github/workflows/sync-public-with-private.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,25 +13,17 @@ jobs:
image: ghcr.io/dfinity/minimal-runner-image:0.1
if: ${{ github.repository != 'dfinity/ic' }}
steps:
- name: Create GitHub App Token
uses: actions/create-github-app-token@v1
id: app-token
with:
# The app used for this is actually PR_AUTOMATION_BOT_PRIVATE, but because the env
# vars need to be the same across both repos, we use the same names as the public one
app-id: ${{ vars.PR_AUTOMATION_BOT_PUBLIC_APP_ID }}
private-key: ${{ secrets.PR_AUTOMATION_BOT_PUBLIC_PRIVATE_KEY }}
- name: Checkout
uses: actions/checkout@v4
with:
ref: 'master-private'
token: ${{ steps.app-token.outputs.token }}

- name: Sync changes from public ic
run: |
git config --global user.name "IDX GitHub Automation"
git config --global user.email "idx@dfinity.org"
git remote add public https://github.com/dfinity/ic.git
git fetch public master
git push origin public/master:master-private
- name: Checkout
uses: actions/checkout@v4
with:
ref: 'master-private'
token: ${{ secrets.PUSH_TO_IC_PRIVATE }}

- name: Sync changes from public ic
run: |
git config --global user.name "IDX GitHub Automation"
git config --global user.email "idx@dfinity.org"
git remote add public https://github.com/dfinity/ic.git
git fetch public master
git push origin public/master:master-private

0 comments on commit c3ae105

Please sign in to comment.