From 6bb886bfa6ebfb60af36b75f946f611690bfdc58 Mon Sep 17 00:00:00 2001 From: senthilrch Date: Thu, 30 Jan 2020 19:04:03 +0530 Subject: [PATCH] made changes to crd validation schema --- deploy/fledged-crd.yaml | 2 +- pkg/apis/fledged/v1alpha1/types.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/deploy/fledged-crd.yaml b/deploy/fledged-crd.yaml index 03e65bf0..7102b8ac 100644 --- a/deploy/fledged-crd.yaml +++ b/deploy/fledged-crd.yaml @@ -21,7 +21,6 @@ spec: type: object required: - spec - - status properties: apiVersion: description: 'APIVersion defines the versioned schema of this representation @@ -74,6 +73,7 @@ spec: required: - message - reason + - startTime - status properties: completionTime: diff --git a/pkg/apis/fledged/v1alpha1/types.go b/pkg/apis/fledged/v1alpha1/types.go index 3c691b51..7e587825 100644 --- a/pkg/apis/fledged/v1alpha1/types.go +++ b/pkg/apis/fledged/v1alpha1/types.go @@ -30,7 +30,7 @@ type ImageCache struct { metav1.ObjectMeta `json:"metadata,omitempty"` Spec ImageCacheSpec `json:"spec"` - Status ImageCacheStatus `json:"status"` + Status ImageCacheStatus `json:"status,omitempty"` } // CacheSpecImages specifies the Images to be cached @@ -51,7 +51,7 @@ type ImageCacheStatus struct { Reason string `json:"reason"` Message string `json:"message"` Failures map[string]NodeReasonMessageList `json:"failures,omitempty"` - StartTime *metav1.Time `json:"startTime,omitempty"` + StartTime *metav1.Time `json:"startTime"` CompletionTime *metav1.Time `json:"completionTime,omitempty"` }