osbuild / bootc-image-builder

A container for deploying bootable container images.
https://osbuild.org
Apache License 2.0
120 stars 51 forks source link

bib: fix injecting default "build" arg into root for flags like --local #615

Closed mvo5 closed 1 month ago

mvo5 commented 1 month ago

[draft as this needs tests]

In PR#608 we dropped the container entrypoint and moved the logic to detect what command to run into the cobra parsing.

However it seems certain situations like:

bootc-image-builder  --type qcow2 --tls-verify=true  --local quay.io/centos-bootc/centos-bootc:stream10

are not detected correctly (thanka to Chunfu Wen for reporting!).

This commit detect this usage and injects the build arg then too.

Closes https://github.com/osbuild/bootc-image-builder/issues/614

achilleas-k commented 1 month ago

I'm going to admin-merge this because we need it to unblock users but we have an issue with our cross-arch build tests that's preventing things from being merged through the proper merge queue.