Skip to content

Commit

Permalink
fix: make sure commit sha is extracted in update-devnet-image-tags
Browse files Browse the repository at this point in the history
  • Loading branch information
bredamatt committed Oct 14, 2024
1 parent 7da2b17 commit 7022e69
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .github/workflows/devnet-ecr-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ jobs:
docker build -t ${{ secrets.AWS_ACCOUNT_ID_AO_DEVNET }}.dkr.ecr.${{ secrets.AWS_REGION_AO_DEVNET }}.amazonaws.com/$REPOSITORY:ao-su-$COMMIT_HASH -f servers/su/Dockerfile.x86 servers/su/
docker push ${{ secrets.AWS_ACCOUNT_ID_AO_DEVNET }}.dkr.ecr.${{ secrets.AWS_REGION_AO_DEVNET }}.amazonaws.com/$REPOSITORY:ao-su-$COMMIT_HASH
update-devnet-commit-sha:
update-devnet-image-tags:
runs-on: ubuntu-latest
needs:
- build-and-push-cu
Expand All @@ -119,6 +119,10 @@ jobs:
env:
GITHUB_USERNAME: bredamatt

- name: Extract shortened commit hash
id: vars
run: echo "COMMIT_HASH=$(echo $GITHUB_SHA | cut -c1-7)" >> $GITHUB_ENV

- name: Update commit-sha.yaml
env:
TRUNCATED_SHA: ${{ env.COMMIT_HASH }}
Expand All @@ -127,5 +131,5 @@ jobs:
sed -i "s/commitSHA: \".*\"/commitSHA: \"${TRUNCATED_SHA}\"/" helmfile/devnet/commit-sha.yaml
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git commit -am "fix: update commit-sha to ${TRUNCATED_SHA} for syncing latest images"
git commit -am "fix: from ao-repo - update commit-sha to ${TRUNCATED_SHA} for syncing latest image tags"
git push https://${{ secrets.AO_TO_CHARTS_PAT }}@github.com/permaweb/charts.git main

0 comments on commit 7022e69

Please sign in to comment.