docker / build-push-action

GitHub Action to build and push Docker images with Buildx
https://github.com/marketplace/actions/build-and-push-docker-images
Apache License 2.0
4.1k stars 525 forks source link

error: Unavailable: connection error: desc = "error reading server preface: http2: frame too large" #1148

Closed IakimLynnyk-TomTom closed 1 week ago

IakimLynnyk-TomTom commented 1 week ago

Contributing guidelines

I've found a bug, and:

Description

Action has thrown error during Post Build and Push step on version v6: Process "docker run" exited with code 1

Expected behaviour

No warnings or errors are expected during execution

Actual behaviour

After build and push action theree were an error thrown on the Post Build and Push step: exporting build record to /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/export /usr/bin/mkfifo /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/buildx-in-II2sr5.fifo /usr/bin/mkfifo /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/buildx-out-z2qe8n.fifo docker buildx --builder builder-ee0b04c5-a221-447e-8d3e-702d89b439da dial-stdio docker run --rm -i -v /home/runner/.docker/buildx/refs:/buildx-refs -v /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/export:/out docker.io/dockereng/export-build:latest --ref-state-dir=/buildx-refs --node=builder-ee0b04c5-a221-447e-8d3e-702d89b439da/builder-ee0b04c5-a221-447e-8d3e-702d89b439da0 --ref=xyka1c9iaxpv5it9mupqp0cp1 --uid=1001 --gid=1001 Unable to find image 'dockereng/export-build:latest' locally latest: Pulling from dockereng/export-build bb431e31f450: Pulling fs layer 03f1761d02d6: Pulling fs layer 03f1761d02d6: Download complete bb431e31f450: Verifying Checksum bb431e31f450: Download complete bb431e31f450: Pull complete 03f1761d02d6: Pull complete Digest: sha256:3dfedea3148487c108965dede834f22e81528fc5b2f3989e4b8ecec2f8fe10ae Status: Downloaded newer image for dockereng/export-build:latest 2024/06/20 11:14:00 error: Unavailable: connection error: desc = "error reading server preface: http2: frame too large" github.com/moby/buildkit/util/stack.Enable /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/stack/stack.go:77 github.com/moby/buildkit/util/grpcerrors.FromGRPC /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/grpcerrors/grpcerrors.go:198 github.com/moby/buildkit/util/grpcerrors.UnaryClientInterceptor /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/grpcerrors/intercept.go:41 google.golang.org/grpc.(*ClientConn).Invoke /go/pkg/mod/google.golang.org/grpc@v1.59.0/call.go:35 github.com/moby/buildkit/api/services/control.(*controlClient).ListWorkers /go/pkg/mod/github.com/moby/buildkit@v0.13.1/api/services/control/control.pb.go:2306 github.com/moby/buildkit/client.(*Client).ListWorkers /go/pkg/mod/github.com/moby/buildkit@v0.13.1/client/workers.go:31 main.run /src/main.go:103 main.main /src/main.go:80 runtime.main /usr/local/go/src/runtime/proc.go:267 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:1650 failed to list workers github.com/moby/buildkit/client.(*Client).ListWorkers /go/pkg/mod/github.com/moby/buildkit@v0.13.1/client/workers.go:33 main.run /src/main.go:103 main.main /src/main.go:80 runtime.main /usr/local/go/src/runtime/proc.go:267 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:1650 failed to list workers main.run /src/main.go:105 main.main /src/main.go:80 runtime.main /usr/local/go/src/runtime/proc.go:267 runtime.goexit /usr/local/go/src/runtime/asm_amd64.s:1650 Warning: Process "docker run" exited with code 1 image

Repository URL

No response

Workflow run URL

No response

YAML workflow

name: building-alpine-images
run-name: building-alpine-images

on:
  push:
    branches:
      - bootstrap
jobs:
  build-push-2-acr:
    runs-on: az-weu-ubuntu-20.04-amd64-05cpu
    environment: test
    steps:
      - name: Get AZ account
        id: azlogin
        uses: azure/login@v2
        with:
          creds: '{
            "clientSecret":  "${{ secrets.K8S_SP_CLIENT_SECRET }}",
            "subscriptionId":  "${{ secrets.ARM_SUBSCRIPTION_ID }}",
            "tenantId":  "${{ secrets.ARM_TENANT_ID }}",
            "clientId":  "${{ secrets.K8S_SP_CLIENT_ID }}"
              }'
      - name: Get ACR Access Token
        id: get-outputs
        uses: azure/CLI@v2
        with:
          azcliversion: latest
          inlineScript: |
            echo "ACCESS_TOKEN=$(az acr login --name ${{ secrets.ACR_REGISTRY_SHORT }} --expose-token 2>/dev/null |jq -r '.accessToken')" >> $GITHUB_ENV
      - name: Checkout repository
        id: checkout
        uses: actions/checkout@v4
        with:
          repository: 'tomtom-internal/cit-ciam-cpk'
          ref: ${{ github.ref }}
      - name: Login to ACR
        id: login
        uses: docker/login-action@v3
        with:
          registry: ${{ secrets.ACR_REGISTRY }}
          username: ${{ secrets.ACR_USERNAME }}
          password: ${{ env.ACCESS_TOKEN }}
      - name: Set up Docker Buildx
        id: buildx
        uses: docker/setup-buildx-action@v3
      - name: Build and push
        id: build
        uses: docker/build-push-action@v6
        with:
          context: ./imagebuid/alpine-default/
          file: ./imagebuid/alpine-default/Dockerfile
          platforms: linux/amd64,linux/arm64
          push: true
          tags: crtestcitciamaks.azurecr.io/alpine:3.20.0_openjdk11.0.23_9p-security-20-06-2024
          builder: ${{ steps.buildx.outputs.name }}

Workflow logs

2024-06-20T11:13:56.4717325Z Post job cleanup.
2024-06-20T11:13:56.9788295Z ##[group]Generating build summary
2024-06-20T11:13:56.9818735Z exporting build record to /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/export
2024-06-20T11:13:57.0458524Z [command]/usr/bin/mkfifo /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/buildx-in-II2sr5.fifo
2024-06-20T11:13:57.0524745Z [command]/usr/bin/mkfifo /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/buildx-out-z2qe8n.fifo
2024-06-20T11:13:57.0553708Z [command]docker buildx --builder builder-ee0b04c5-a221-447e-8d3e-702d89b439da dial-stdio
2024-06-20T11:13:57.0577320Z [command]docker run --rm -i -v /home/runner/.docker/buildx/refs:/buildx-refs -v /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/export:/out docker.io/dockereng/export-build:latest --ref-state-dir=/buildx-refs --node=builder-ee0b04c5-a221-447e-8d3e-702d89b439da/builder-ee0b04c5-a221-447e-8d3e-702d89b439da0 --ref=xyka1c9iaxpv5it9mupqp0cp1 --uid=1001 --gid=1001
2024-06-20T11:13:57.1462950Z Unable to find image 'dockereng/export-build:latest' locally
2024-06-20T11:13:58.2874077Z latest: Pulling from dockereng/export-build
2024-06-20T11:13:58.5818966Z bb431e31f450: Pulling fs layer
2024-06-20T11:13:58.5819463Z 03f1761d02d6: Pulling fs layer
2024-06-20T11:13:58.9697380Z 03f1761d02d6: Download complete
2024-06-20T11:13:59.0796443Z bb431e31f450: Verifying Checksum
2024-06-20T11:13:59.0797041Z bb431e31f450: Download complete
2024-06-20T11:13:59.7543186Z bb431e31f450: Pull complete
2024-06-20T11:13:59.9877695Z 03f1761d02d6: Pull complete
2024-06-20T11:13:59.9921587Z Digest: sha256:3dfedea3148487c108965dede834f22e81528fc5b2f3989e4b8ecec2f8fe10ae
2024-06-20T11:13:59.9931986Z Status: Downloaded newer image for dockereng/export-build:latest
2024-06-20T11:14:00.2663244Z 2024/06/20 11:14:00 error: Unavailable: connection error: desc = "error reading server preface: http2: frame too large"
2024-06-20T11:14:00.2664500Z github.com/moby/buildkit/util/stack.Enable
2024-06-20T11:14:00.2665124Z    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/stack/stack.go:77
2024-06-20T11:14:00.2665824Z github.com/moby/buildkit/util/grpcerrors.FromGRPC
2024-06-20T11:14:00.2666494Z    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/grpcerrors/grpcerrors.go:198
2024-06-20T11:14:00.2667251Z github.com/moby/buildkit/util/grpcerrors.UnaryClientInterceptor
2024-06-20T11:14:00.2667995Z    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/grpcerrors/intercept.go:41
2024-06-20T11:14:00.2668630Z google.golang.org/grpc.(*ClientConn).Invoke
2024-06-20T11:14:00.2669133Z    /go/pkg/mod/google.golang.org/grpc@v1.59.0/call.go:35
2024-06-20T11:14:00.2669811Z github.com/moby/buildkit/api/services/control.(*controlClient).ListWorkers
2024-06-20T11:14:00.2670860Z    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/api/services/control/control.pb.go:2306
2024-06-20T11:14:00.2671604Z github.com/moby/buildkit/client.(*Client).ListWorkers
2024-06-20T11:14:00.2672212Z    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/client/workers.go:31
2024-06-20T11:14:00.2672720Z main.run
2024-06-20T11:14:00.2672979Z    /src/main.go:103
2024-06-20T11:14:00.2673247Z main.main
2024-06-20T11:14:00.2673492Z    /src/main.go:80
2024-06-20T11:14:00.2673757Z runtime.main
2024-06-20T11:14:00.2674045Z    /usr/local/go/src/runtime/proc.go:267
2024-06-20T11:14:00.2674450Z runtime.goexit
2024-06-20T11:14:00.2674726Z    /usr/local/go/src/runtime/asm_amd64.s:1650
2024-06-20T11:14:00.2675088Z failed to list workers
2024-06-20T11:14:00.2675448Z github.com/moby/buildkit/client.(*Client).ListWorkers
2024-06-20T11:14:00.2675985Z    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/client/workers.go:33
2024-06-20T11:14:00.2676430Z main.run
2024-06-20T11:14:00.2676659Z    /src/main.go:103
2024-06-20T11:14:00.2676910Z main.main
2024-06-20T11:14:00.2677139Z    /src/main.go:80
2024-06-20T11:14:00.2677388Z runtime.main
2024-06-20T11:14:00.2677650Z    /usr/local/go/src/runtime/proc.go:267
2024-06-20T11:14:00.2678000Z runtime.goexit
2024-06-20T11:14:00.2678287Z    /usr/local/go/src/runtime/asm_amd64.s:1650
2024-06-20T11:14:00.2678652Z failed to list workers
2024-06-20T11:14:00.2679190Z main.run
2024-06-20T11:14:00.2679423Z    /src/main.go:105
2024-06-20T11:14:00.2679673Z main.main
2024-06-20T11:14:00.2679901Z    /src/main.go:80
2024-06-20T11:14:00.2680148Z runtime.main
2024-06-20T11:14:00.2680411Z    /usr/local/go/src/runtime/proc.go:267
2024-06-20T11:14:00.2680751Z runtime.goexit
2024-06-20T11:14:00.2681038Z    /usr/local/go/src/runtime/asm_amd64.s:1650
2024-06-20T11:14:00.5202922Z ##[warning]Process "docker run" exited with code 1
2024-06-20T11:14:00.5204898Z ##[endgroup]
2024-06-20T11:14:00.5205961Z ##[group]Removing temp folder /home/runner/_work/_temp/docker-actions-toolkit-qspPkS
2024-06-20T11:14:00.5213402Z ##[endgroup]
2024-06-20T11:14:00.5213964Z ##[group]Post cache
2024-06-20T11:14:00.5215245Z State not set
2024-06-20T11:14:00.5216464Z ##[endgroup]

BuildKit logs

Post job cleanup.
Generating build summary
  exporting build record to /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/export
  /usr/bin/mkfifo /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/buildx-in-II2sr5.fifo
  /usr/bin/mkfifo /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/buildx-out-z2qe8n.fifo
  docker buildx --builder builder-ee0b04c5-a221-447e-8d3e-702d89b439da dial-stdio
  docker run --rm -i -v /home/runner/.docker/buildx/refs:/buildx-refs -v /home/runner/_work/_temp/docker-actions-toolkit-ByV9LI/export:/out docker.io/dockereng/export-build:latest --ref-state-dir=/buildx-refs --node=builder-ee0b04c5-a221-447e-8d3e-702d89b439da/builder-ee0b04c5-a221-447e-8d3e-702d89b439da0 --ref=xyka1c9iaxpv5it9mupqp0cp1 --uid=1001 --gid=1001
  Unable to find image 'dockereng/export-build:latest' locally
  latest: Pulling from dockereng/export-build
  bb431e31f450: Pulling fs layer
  03f1761d02d6: Pulling fs layer
  03f1761d02d6: Download complete
  bb431e31f450: Verifying Checksum
  bb431e31f450: Download complete
  bb431e31f450: Pull complete
  03f1761d02d6: Pull complete
  Digest: sha256:3dfedea3148487c108965dede834f22e81528fc5b2f3989e4b8ecec2f8fe10ae
  Status: Downloaded newer image for dockereng/export-build:latest
  2024/06/20 11:14:00 error: Unavailable: connection error: desc = "error reading server preface: http2: frame too large"
  github.com/moby/buildkit/util/stack.Enable
    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/stack/stack.go:77
  github.com/moby/buildkit/util/grpcerrors.FromGRPC
    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/grpcerrors/grpcerrors.go:198
  github.com/moby/buildkit/util/grpcerrors.UnaryClientInterceptor
    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/util/grpcerrors/intercept.go:41
  google.golang.org/grpc.(*ClientConn).Invoke
    /go/pkg/mod/google.golang.org/grpc@v1.59.0/call.go:35
  github.com/moby/buildkit/api/services/control.(*controlClient).ListWorkers
    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/api/services/control/control.pb.go:2306
  github.com/moby/buildkit/client.(*Client).ListWorkers
    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/client/workers.go:31
  main.run
    /src/main.go:103
  main.main
    /src/main.go:80
  runtime.main
    /usr/local/go/src/runtime/proc.go:267
  runtime.goexit
    /usr/local/go/src/runtime/asm_amd64.s:1650
  failed to list workers
  github.com/moby/buildkit/client.(*Client).ListWorkers
    /go/pkg/mod/github.com/moby/buildkit@v0.13.1/client/workers.go:33
  main.run
    /src/main.go:103
  main.main
    /src/main.go:80
  runtime.main
    /usr/local/go/src/runtime/proc.go:267
  runtime.goexit
    /usr/local/go/src/runtime/asm_amd64.s:1650
  failed to list workers
  main.run
    /src/main.go:105
  main.main
    /src/main.go:80
  runtime.main
    /usr/local/go/src/runtime/proc.go:267
  runtime.goexit
    /usr/local/go/src/runtime/asm_amd64.s:1650
  Warning: Process "docker run" exited with code 1

Additional info

It is fixed once swithed v6 -> v5

crazy-max commented 1 week ago

duplicate of #1143

this is already fixed but not yet released

crazy-max commented 1 week ago

Should be good with latest v6.0.2