Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build summary does not include images created with matrix #299

Open
3 tasks done
betelgeuse opened this issue Jan 29, 2025 · 4 comments
Open
3 tasks done

Build summary does not include images created with matrix #299

betelgeuse opened this issue Jan 29, 2025 · 4 comments

Comments

@betelgeuse
Copy link

Contributing guidelines

I've found a bug, and:

  • The documentation does not mention anything about my problem
  • There are no open or closed issues that are related to my problem

Description

I have a bake configuration that uses matrix:

target "foo1" {
  matrix {
    VAR = ["a", "b", "c"]
  }
}

target "foo2" {
}

Expected behaviour

Build summary includes foo1 images

Actual behaviour

Build summary only includes foo2 image

Repository URL

No response

Workflow run URL

No response

YAML workflow

- name: Build and push
        uses: docker/bake-action@v6
        with:
          source: .
          provenance: false
          targets: foo1,foo2

Workflow logs

No response

BuildKit logs


Additional info

No response

@crazy-max
Copy link
Member

Can you show workflow logs or give a link to your repo please?

@betelgeuse
Copy link
Author

betelgeuse commented Jan 29, 2025

Can you show workflow logs or give a link to your repo please?

Here's the log:

  exporting build record to /opt/actions-runner/_work/_temp/docker-actions-toolkit-CTdtNn/export
  /usr/bin/mkfifo /opt/actions-runner/_work/_temp/docker-actions-toolkit-CTdtNn/buildx-in-3RQEKI.fifo
  /usr/bin/mkfifo /opt/actions-runner/_work/_temp/docker-actions-toolkit-CTdtNn/buildx-out-vx70KW.fifo
  docker buildx --builder builder-fc3bf888-9fa6-4895-a76c-d03d0aab82c0 dial-stdio
  docker run --rm -i -v /root/.docker/buildx/refs:/buildx-refs -v /opt/actions-runner/_work/_temp/docker-actions-toolkit-CTdtNn/export:/out docker.io/dockereng/export-build:latest --ref-state-dir=/buildx-refs --node=builder-fc3bf888-9fa6-4895-a76c-d03d0aab82c0/builder-fc3bf888-9fa6-4895-a76c-d03d0aab82c00 --ref=pgaxr41hpzt4xytnnxhtc5jaz --ref=w3701c495rlexg75xy63igus5 --ref=i64658d03mokuzinxgq8vuifg --uid=0 --gid=0
  Unable to find image 'dockereng/export-build:latest' locally
  latest: Pulling from dockereng/export-build
  fa05fab17045: Pulling fs layer
  3bee4e1c34fe: Pulling fs layer
  3bee4e1c34fe: Download complete
  fa05fab17045: Verifying Checksum
  fa05fab17045: Download complete
  fa05fab17045: Pull complete
  3bee4e1c34fe: Pull complete
  Digest: sha256:3d41f110aedbe6c439e0002646f6c31b3063bc50f43a712c9a55710a9b5ae3f7
  Status: Downloaded newer image for dockereng/export-build:latest
  Process "docker run" exited with code 0
  Parsing /opt/actions-runner/_work/_temp/docker-actions-toolkit-CTdtNn/export/summary.json
  Build records written to /opt/actions-runner/_work/_temp/docker-actions-toolkit-CTdtNn/export/<REPO>~PGAXR4+2.dockerbuild (247.21 KB)
  Uploading <REPO>~PGAXR4+2.dockerbuild to blob storage
  Process "buildx dial-stdio" was killed with signal SIGKILL
  Beginning upload of artifact content to blob storage
  Uploaded bytes 65536
  Uploaded bytes 131072
  Uploaded bytes 196608
  Uploaded bytes 253144
  Finished uploading artifact content to blob storage!
  SHA256 hash of uploaded artifact is 3045ac8442ce5a1bb0138b59fe83e32073bb51080a6136a4bc7f8020d4597f5b
  Finalizing artifact upload
  Artifact successfully finalized (2503155721)
  Artifact download URL: https://github.com/<ARTIFACT_PATH>
  Writing summary

Entries like <REPO> are my scrubbing.

@crazy-max
Copy link
Member

crazy-max commented Jan 29, 2025

--ref=w3701c495rlexg75xy63igus5 --ref=i64658d03mokuzinxgq8vuifg

I see it exports two refs here and I guess it should be three.

Can you show the docker/bake-action@v6 logs please? Would like to see the Bake definition output like https://github.com/docker/bake-action/actions/runs/13028830780/job/36343369617#step:6:213

And also the Metadata https://github.com/docker/bake-action/actions/runs/13028830780/job/36343369617#step:6:306 and Build references https://github.com/docker/bake-action/actions/runs/13028830780/job/36343369617#step:6:387

Thanks

@betelgeuse
Copy link
Author

--ref=w3701c495rlexg75xy63igus5 --ref=i64658d03mokuzinxgq8vuifg

I see it exports two refs here and I guess it should be three.

Can you show the docker/bake-action@v6 logs please? Would like to see the Bake definition output like https://github.com/docker/bake-action/actions/runs/13028830780/job/36343369617#step:6:213

The whole log is full of lines that would need scrubbing but it's only just our own build output. Example lines for matrix images are like

#159 [foo1-a] exporting to image
#159 pushing layers 3.8s done
#159 ...

And also the Metadata https://github.com/docker/bake-action/actions/runs/13028830780/job/36343369617#step:6:306 and Build references https://github.com/docker/bake-action/actions/runs/13028830780/job/36343369617#step:6:387

Metadata is probably relevant. It has much more output for foo2 than foo1. foo1 entries are output like:

    "foo1-a": {
      "containerimage.digest": "sha256:fd0a44ef71590ffd6a24d965f0bf76d8b4cbf0fab7f77beeff75317dbcf03278"
    },
    "foo1-b": {
      "containerimage.digest": "sha256:da1731a3b50ddda9fd50ad84ee6a3602349e39c8107b7d8ae1a64b634c57d106"
    },

Build references:

  builder-<UUID1>/builder-<UUID1>/<ID1>
  builder-<UUID1>/builder-<UUID1>/<ID2>
  builder-<UUID1>/builder-<UUID1>/<ID3>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants