Skip to content

Commit

Permalink
lca - ibu: additionionalImages option is added. (openshift-kni#245)
Browse files Browse the repository at this point in the history
This will allow providing a configmap reference with
additional images.

Signed-off-by: Alexander Chuzhoy <[email protected]>
  • Loading branch information
achuzhoy authored Feb 12, 2024
1 parent e6f9769 commit 928a017
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions pkg/lca/imagebasedupgrade.go
Original file line number Diff line number Diff line change
Expand Up @@ -223,6 +223,22 @@ func (builder *ImageBasedUpgradeBuilder) WithSeedImage(
return builder
}

// WithAdditionalImages adds additionalImages to be used by the imagebasedupgrade.
func (builder *ImageBasedUpgradeBuilder) WithAdditionalImages(
additionalImagesConfigMapName, additionalImagesConfigMapNamespace string) *ImageBasedUpgradeBuilder {
if valid, _ := builder.validate(); !valid {
return builder
}

glog.V(100).Infof("Setting additionalImages configmap name %s in namespace %s in the imagebasedupgrade",
additionalImagesConfigMapName, additionalImagesConfigMapNamespace)

builder.Definition.Spec.AdditionalImages =
lcav1alpha1.ConfigMapRef{Name: additionalImagesConfigMapName, Namespace: additionalImagesConfigMapNamespace}

return builder
}

// WithExtraManifests adds extraManifests to be used by the imagebasedupgrade.
// This is used to create/configure resources during upgrade.
func (builder *ImageBasedUpgradeBuilder) WithExtraManifests(
Expand Down

0 comments on commit 928a017

Please sign in to comment.