-
Bug
-
Resolution: Done-Errata
-
None
-
Quality / Stability / Reliability
-
False
-
-
False
-
CLOSED
-
CNV I/U Operators Sprint 220
-
No
Description of problem: As per upstream documentation: https://github.com/kubevirt/hyperconverged-cluster-operator/blob/main/docs/cluster-configuration.md#disabling-a-common-golden-image, while disabling a data import cron, user should not have to enter the whole spec of the dataimportcrontemplate. But currently the validation fails if the whole spec is not provided
Version-Release number of selected component (if applicable):
4.11.0
How reproducible:
100%
Steps to Reproduce:
1. Edit hco and attempt to disable any golden image with only metadata section with annotation and name.
2. HCO rejects the update
3.
Actual results:
==========
- Please edit the object below. Lines beginning with a '#' will be ignored,
- and an empty file will abort the edit. If an error occurs while saving this file will be
- reopened with the relevant failures.
# - hyperconvergeds.hco.kubevirt.io "kubevirt-hyperconverged" was not valid:
- * <nil>: Invalid value: "The edited file failed validation": ValidationError(HyperConverged.spec.dataImportCronTemplates[0]): missing required field "spec" in io.kubevirt.hco.v1beta1.HyperConverged.spec.dataImportCronTemplates
#
apiVersion: hco.kubevirt.io/v1beta1
kind: HyperConverged
metadata:
creationTimestamp: "2022-05-20T01:42:08Z"
finalizers:
- kubevirt.io/hyperconverged
generation: 38
labels:
app: kubevirt-hyperconverged
name: kubevirt-hyperconverged
namespace: openshift-cnv
resourceVersion: "23952285"
uid: fc316af2-13e5-48c0-990d-24d2cda71b7c
spec:
dataImportCronTemplates: - metadata:
annotations:
cdi.kubevirt.io/storage.bind.immediate.requested: "true"
dataimportcrontemplate.kubevirt.io/enable: 'false'
name: centos-7-image-cron
certConfig:
ca:
duration: 48h0m0s
renewBefore: 24h0m0s
server:
duration: 24h0m0s
renewBefore: 12h0m0s
featureGates:
deployTektonTaskResources: false
enableCommonBootImageImport: true
nonRoot: true
sriovLiveMigration: true
withHostPassthroughCPU: false
liveMigrationConfig:
======================
Expected results:
User should not have to provide the whole spec and metadata section of a golden image while disabling it
Additional info: