cog icon indicating copy to clipboard operation
cog copied to clipboard

fix: Always pass `--load` during docker build

Open danfairs opened this issue 7 months ago • 2 comments

This change modifies Cog so that it always passes --load during docker build.

Previously, it would only pass this flag if running on Apple Silicon. I don't think that is quite the right check - it is actually down to the build driver in use. Cog seems to assume that the image will always be loaded into Docker, so unconditionally passing --load seems to be the right thing to do.

I had to include this change to allow builds to complete successfully on a self-hosted Linux GH CI runner.

I have included tests for the new behaviour, plus some coverage of existing behaviours with different ImageBuildOption settings in place.

Fixes #2329.

danfairs avatar May 15 '25 08:05 danfairs

@danfairs I'm happy to rebase and fix conflicts with main, but I'll need permission to your fork. I want to get this in, just let me know how to help 😄

michaeldwan avatar May 19 '25 22:05 michaeldwan

@danfairs I'm happy to rebase and fix conflicts with main, but I'll need permission to your fork. I want to get this in, just let me know how to help 😄

Thanks! I'm actually away for the next week or so but can sort this out when I'm back 👍

danfairs avatar May 26 '25 13:05 danfairs