name: Build Docker image on: push: branches: - main jobs: docker-amd64: if: github.repository == 'OpenWF/SpaceNinjaServer' runs-on: amd64 steps: - name: Set up Docker buildx uses: docker/setup-buildx-action@v3 - name: Log in to container registry uses: docker/login-action@v3 with: username: openwf password: ${{ secrets.DOCKERHUB_TOKEN }} - name: Build and push uses: docker/build-push-action@v6 with: platforms: linux/amd64 push: true tags: | openwf/spaceninjaserver:latest openwf/spaceninjaserver:${{ github.sha }} docker-arm64: if: github.repository == 'OpenWF/SpaceNinjaServer' runs-on: arm64 steps: - name: Set up Docker buildx uses: docker/setup-buildx-action@v3 - name: Log in to container registry uses: docker/login-action@v3 with: username: openwf password: ${{ secrets.DOCKERHUB_TOKEN }} - name: Build and push uses: docker/build-push-action@v6 with: platforms: linux/arm64 push: true tags: | openwf/spaceninjaserver:latest-arm64 openwf/spaceninjaserver:${{ github.sha }}-arm64