diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 881752f4..3192bbd4 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -35,6 +35,9 @@ jobs: - uses: actions/checkout@v2 - uses: superfly/flyctl-actions/setup-flyctl@master + - name: Add SHORT_SHA env property with commit short sha + run: echo "SHORT_SHA=`echo ${GITHUB_SHA} | cut -c1-8`" >> $GITHUB_ENV + - name: Deploy API - # deploy the image from ghcr.io for the target sha - run: flyctl deploy --image ghcr.io/a-type/biscuits:${{ github.sha }} + # deploy the image from ghcr.io for the target sha (short version) + run: flyctl deploy --image ghcr.io/a-type/biscuits:sha-${SHORT_SHA}