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.11k stars 527 forks source link

outputs.digest not set if push = false #1009

Closed EajksEajks closed 7 months ago

EajksEajks commented 7 months ago

Contributing guidelines

I've found a bug, and:

Description

I have a GitHub workflow where I chain several docker build/push using the outputs.digest from one docker build/push to the next one. I only push on schedule/tags and it works fine. But on branches, I do not push but it doesn't work because outputs.digest is not set.

Expected behaviour

outputs.digest set independent of push being true or false

Actual behaviour

outputs.digest set only on push = true

Repository URL

https://github.com/by-EAjks-Com/Development-Environments

Workflow run URL

https://github.com/by-EAjks-Com/Development-Environments/actions/runs/6919392268

YAML workflow

https://github.com/by-EAjks-Com/Development-Environments/blob/main/.github/workflows/build-deploy-cpp-only.yaml

Workflow logs

No response

BuildKit logs

No response

Additional info

No response

crazy-max commented 7 months ago

But on branches, I do not push but it doesn't work because outputs.digest is not set.

This is expected if you don't export the build result (load or push).