diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index a4dbc9b..ade2a61 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -9,42 +9,8 @@ env: IMAGE_NAME: ${{ github.repository }} jobs: - build_x64: - name: Build x64 - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v2 - - - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v1 - - - name: Log in to the Container registry - uses: docker/login-action@v2 - with: - registry: ${{ env.REGISTRY }} - username: ${{ github.actor }} - password: ${{ secrets.GITHUB_TOKEN }} - - - name: Extract metadata (tags, labels) for Docker - id: meta - uses: docker/metadata-action@9ec57ed1fcdbf14dcef7dfbe97b2010124a938b7 - with: - images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} - - - name: Build and push - uses: docker/build-push-action@v2 - with: - context: . - file: ./Dockerfile - platforms: linux/amd64 - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - - build_arm64: - name: Build ARM64 + build: + name: Build Multiarch runs-on: ubuntu-latest steps: @@ -75,7 +41,9 @@ jobs: with: context: . file: ./Dockerfile - platforms: linux/arm64 + platforms: linux/arm64, linux/amd64 push: true tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} \ No newline at end of file + labels: ${{ steps.meta.outputs.labels }} + cache-from: type=gha + cache-to: type=gha,mode=max \ No newline at end of file