From b228886fe11c7ee78c10932a2b8e39f259bdff14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Budai?= Date: Fri, 6 Oct 2023 11:40:28 +0200 Subject: [PATCH] cmd/gen-manifests: fix compilation with the latest images MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The latest images introduced a new blueprint option: minimal. Since we use direct type-conversion, we need to add it also in gen-manifests. A warning is also added, since this feature is considered experimental. Signed-off-by: Ondřej Budai --- cmd/gen-manifests/main.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cmd/gen-manifests/main.go b/cmd/gen-manifests/main.go index c8b5248e07..f9ed50bc83 100644 --- a/cmd/gen-manifests/main.go +++ b/cmd/gen-manifests/main.go @@ -25,6 +25,7 @@ import ( "github.com/osbuild/images/pkg/ostree" "github.com/osbuild/images/pkg/rhsm/facts" "github.com/osbuild/images/pkg/rpmmd" + "github.com/osbuild/osbuild-composer/internal/dnfjson" ) @@ -73,6 +74,9 @@ type crBlueprint struct { Containers []blueprint.Container `json:"containers,omitempty"` Customizations *blueprint.Customizations `json:"customizations,omitempty"` Distro string `json:"distro,omitempty"` + + // EXPERIMENTAL + Minimal bool `json:"minimal,omitempty"` } type composeRequest struct { @@ -150,6 +154,9 @@ func makeManifestJob(name string, imgType distro.ImageType, cr composeRequest, d var bp blueprint.Blueprint if cr.Blueprint != nil { bp = blueprint.Blueprint(*cr.Blueprint) + if bp.Minimal { + msgq <- fmt.Sprintf("[%s] blueprint contains minimal=true, this is considered EXPERIMENTAL", filename) + } } manifest, _, err := imgType.Manifest(&bp, options, repos, seedArg)