8.2.3. Adding a custom golden image in a heterogeneous cluster
Golden image support for heterogeneous clusters is a Technology Preview feature only. Technology Preview features are not supported with Red Hat production service level agreements (SLAs) and might not be functionally complete. Red Hat does not recommend using them in production. These features provide early access to upcoming product features, enabling customers to test functionality and provide feedback during the development process.
For more information about the support scope of Red Hat Technology Preview features, see Technology Preview Features Support Scope.
Add a custom golden image in a heterogeneous cluster by setting the ssp.kubevirt.io/dict.architectures annotation in the spec.dataImportCronTemplates.metadata.annotations stanza of the HyperConverged custom resource (CR). This annotation lists the architectures supported by the image.
Prerequisites
-
You have installed the OpenShift CLI (
oc).
Procedure
Open the
HyperConvergedCR in your default editor by running the following command:$ oc edit hyperconverged kubevirt-hyperconverged -n openshift-cnvEdit the
HyperConvergedCR, to add the custom golden image. You must add the appropriate values forssp.kubevirt.io/dict.architecturesannotation in thedataImportCronTemplatessection. For example:apiVersion: hco.kubevirt.io/v1beta1 kind: HyperConverged metadata: name: kubevirt-hyperconverged spec: dataImportCronTemplates: - metadata: name: custom-image1 annotations: ssp.kubevirt.io/dict.architectures: "<architecture_list>" spec: schedule: "0 */12 * * *" template: spec: source: registry: url: docker://myprivateregistry/custom1 managedDataSource: custom1 retentionPolicy: "All" #...where:
<architecture_list>Specifies a comma-separated list of supported architectures for this image. For example, if the image supports
amd64andarm64architectures, the value would be"amd64,arm64".注記An image may support more architectures than you want to use in your cluster. You do not have to list all of the architectures an image supports, only those for which you want to create a boot source.
-
Save and exit the editor to update the
HyperConvergedCR.