Skip to content

Commit

Permalink
fix: add change for token 403 failure
Browse files Browse the repository at this point in the history
sync script not working
  • Loading branch information
Mossman1215 committed Sep 11, 2024
1 parent a64d300 commit 04b2b21
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/sync.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,14 @@ jobs:
if: github.ref_name == 'main'
- name: prepare auth podman
env:
GHCR_USER: geonetci
GHCR_TOKEN: ${{ secrets.GH_CI_USER_TOKEN }}
DOCKER_TOKEN: ${{ secrets.DOCKER_TOKEN }}
DOCKER_USER: geonetci
RUN_ECR: ${{ github.ref_name == 'main' || 'FALSE' }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
auth_tmp=$(mktemp)
echo '{}' > $auth_tmp # JSON formating is required
echo -n $GHCR_TOKEN | podman login --authfile=$auth_tmp -u $GHCR_USER --password-stdin ghcr.io
podman login --authfile=$auth_tmp -u ${{ github.actor }} --password $GH_TOKEN ghcr.io
echo -n $DOCKER_TOKEN | podman login --authfile=$auth_tmp -u $DOCKER_USER --password-stdin docker.io
if [ "$RUN_ECR" != "FALSE" ]; then
aws ecr get-login-password --region ap-southeast-2 | podman login "$ECR" -u AWS --password-stdin
Expand Down

0 comments on commit 04b2b21

Please sign in to comment.