diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 11a5ced..6874241 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -21,62 +21,12 @@ jobs: - name: Checkout uses: actions/checkout@v3 - - name: Set up QEMU - uses: docker/setup-qemu-action@v2 - - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 - - - name: Log into the container registry - uses: docker/login-action@v2 + - name: Run Bento build action + uses: bento-platform/bento_build_action@v0.3 with: registry: ghcr.io - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - - name: Set up development image metadata - id: meta-dev - uses: docker/metadata-action@v4 - with: - images: | - ghcr.io/bento-platform/bento_event_relay - flavor: | - latest=false - tags: | - type=raw,value=latest-dev,enable={{is_default_branch}} - type=ref,event=pr - type=sha,prefix=sha- - - - name: Build and push development image - uses: docker/build-push-action@v3 - with: - context: . - file: Dockerfile - push: true - tags: ${{ steps.meta-dev.outputs.tags }} - labels: ${{ steps.meta-dev.outputs.labels }} - platforms: linux/amd64,linux/arm64 - - - name: Set up production image metadata - id: meta - uses: docker/metadata-action@v4 - if: ${{ github.event_name == 'release' }} - with: - images: | - ghcr.io/bento-platform/bento_event_relay - flavor: | - latest=true - tags: | - type=semver,pattern={{version}} - type=semver,pattern={{major}}.{{minor}} - - - name: Build and push production image - uses: docker/build-push-action@v3 - if: ${{ github.event_name == 'release' }} - with: - context: . - file: Dockerfile - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - platforms: linux/amd64,linux/arm64 + registry-username: ${{ github.actor }} + registry-password: ${{ secrets.GITHUB_TOKEN }} + image-name: ghcr.io/bento-platform/bento_event_relay + development-dockerfile: Dockerfile + production-dockerfile: Dockerfile