From 917c6ccb054f68198dac265d5d522cb6b9e5f814 Mon Sep 17 00:00:00 2001 From: hanna littorin Date: Tue, 21 Jul 2026 08:08:45 +0200 Subject: [PATCH] Fix Heroku container push failing with "unsupported" media type BuildKit v0.31.0 changed the image exporter to default to OCI media types for all pushes (previously only when attestations/annotations were present). Heroku's container registry only supports the legacy Docker v2 schema2 manifest format, so pushes started failing with: ERROR: failed to push registry.heroku.com//: unsupported Explicitly set oci-mediatypes=false via --output to keep pushing the legacy format regardless of the BuildKit version pulled by the floating moby/buildkit:buildx-stable-1 tag. --- .github/workflows/heroku-container.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/heroku-container.yml b/.github/workflows/heroku-container.yml index 5ebcb94..43eb268 100644 --- a/.github/workflows/heroku-container.yml +++ b/.github/workflows/heroku-container.yml @@ -110,11 +110,10 @@ jobs: for target in $TARGETS; do docker buildx build \ --target "$target" \ - --tag "registry.heroku.com/$APP/$target" \ + --output "type=image,name=registry.heroku.com/$APP/$target,push=true,oci-mediatypes=false" \ --cache-from type=gha \ --cache-to type=gha,mode=max \ --provenance=false \ - --push \ "${args[@]}" \ "${secrets[@]}" \ .