diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..8414b33 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,29 @@ +name: Release + +on: + release: + types: [created] + +jobs: + ghcr: + name: Publish to GHCR + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + - uses: docker/setup-qemu-action@v3 + - uses: docker/setup-buildx-action@v3 + - uses: docker/build-push-action@v5 + with: + push: true + target: web + platforms: linux/amd64,linux/arm64/v8 + cache-from: type=gha + cache-to: type=gha,mode=max + tags: | + ghcr.io/stackmasters/node-sample:${{ github.event.release.name }} + ghcr.io/stackmasters/node-sample:latest \ No newline at end of file