diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 272025b..1893a6a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -25,6 +25,15 @@ jobs: - name: Build site tools run: cd tools/deploy_aws_s3 && cargo build --verbose + - name: Tar site tools + run: tar -C tools/deploy_aws_s3/debug -cvf deploy_aws_s3.tar deploy_aws_s3 + + - name: Save tools artifact + uses: actions/upload-artifact@v4 + with: + name: deploy_aws_s3 + path: deploy_aws_s3.tar + - name: Build site run: make build @@ -34,12 +43,6 @@ jobs: name: website-${{ github.ref_name }} path: public/ - - name: Save tools artifact - uses: actions/upload-artifact@v4 - with: - name: deploy_aws_s3 - path: tools/deploy_aws_s3/target/*/deploy_aws_s3 - call-deploy-workflow: uses: ./.github/workflows/deploy.yml needs: build diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index afbfb07..153c28b 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -35,7 +35,10 @@ jobs: uses: actions/download-artifact@v4 with: name: deploy_aws_s3 - path: tools/deploy_aws_s3 + path: deploy_aws_s3.tar + + - name: Extract tools artifact + run: tar -xvf deploy_aws_s3.tar - name: Setup Credentials uses: aws-actions/configure-aws-credentials@v4 @@ -46,7 +49,7 @@ jobs: - name: Upload website to S3 #run: aws s3 sync --acl public-read --delete public/ s3://${{ env.S3_BUCKET }}/ - run: tools/deploy_aws_s3/debug/deploy_aws_s3 --bucket ${{ env.S3_BUCKET }} public/ -v -a public-read -d + run: deploy_aws_s3 --bucket ${{ env.S3_BUCKET }} public/ -v -a public-read -d # invalidate-cache: # runs-on: ubuntu-latest