diff --git a/api/v1alpha1/irsasetup_types.go b/api/v1alpha1/irsasetup_types.go index 5385636..dab2ea4 100644 --- a/api/v1alpha1/irsasetup_types.go +++ b/api/v1alpha1/irsasetup_types.go @@ -71,8 +71,14 @@ type SecretRef struct { // IRSASetupStatus defines the observed state of IRSASetup type IRSASetupStatus struct { - // INSERT ADDITIONAL STATUS FIELD - define observed state of cluster - // Important: Run "make" to regenerate code after modifying this file + SelfHostedSetup CommonStatus `json:"selfHostedSetup,omitempty"` + CommonSetup CommonStatus `json:"commonSetup,omitempty"` +} + +// CommonStatus is a set of status attributes +type CommonStatus struct { + Healthy bool `json:"healthy"` + Errors []string `json:"errors,omitempty"` } //+kubebuilder:object:root=true diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go index 096bd18..1aa3344 100644 --- a/api/v1alpha1/zz_generated.deepcopy.go +++ b/api/v1alpha1/zz_generated.deepcopy.go @@ -40,6 +40,26 @@ func (in *Auth) DeepCopy() *Auth { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *CommonStatus) DeepCopyInto(out *CommonStatus) { + *out = *in + if in.Errors != nil { + in, out := &in.Errors, &out.Errors + *out = make([]string, len(*in)) + copy(*out, *in) + } +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CommonStatus. +func (in *CommonStatus) DeepCopy() *CommonStatus { + if in == nil { + return nil + } + out := new(CommonStatus) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *Discovery) DeepCopyInto(out *Discovery) { *out = *in @@ -62,7 +82,7 @@ func (in *IRSASetup) DeepCopyInto(out *IRSASetup) { out.TypeMeta = in.TypeMeta in.ObjectMeta.DeepCopyInto(&out.ObjectMeta) out.Spec = in.Spec - out.Status = in.Status + in.Status.DeepCopyInto(&out.Status) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IRSASetup. @@ -135,6 +155,8 @@ func (in *IRSASetupSpec) DeepCopy() *IRSASetupSpec { // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *IRSASetupStatus) DeepCopyInto(out *IRSASetupStatus) { *out = *in + in.SelfHostedSetup.DeepCopyInto(&out.SelfHostedSetup) + in.CommonSetup.DeepCopyInto(&out.CommonSetup) } // DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new IRSASetupStatus. diff --git a/config/crd/bases/irsa.kkb0318.github.io_irsasetups.yaml b/config/crd/bases/irsa.kkb0318.github.io_irsasetups.yaml index 1b5cd92..c3fbfb2 100644 --- a/config/crd/bases/irsa.kkb0318.github.io_irsasetups.yaml +++ b/config/crd/bases/irsa.kkb0318.github.io_irsasetups.yaml @@ -91,6 +91,31 @@ spec: type: object status: description: IRSASetupStatus defines the observed state of IRSASetup + properties: + commonSetup: + description: CommonStatus is a set of status attributes + properties: + errors: + items: + type: string + type: array + healthy: + type: boolean + required: + - healthy + type: object + selfHostedSetup: + description: CommonStatus is a set of status attributes + properties: + errors: + items: + type: string + type: array + healthy: + type: boolean + required: + - healthy + type: object type: object type: object served: true diff --git a/docs/config.yaml b/docs/config.yaml index b6ff483..0755c12 100644 --- a/docs/config.yaml +++ b/docs/config.yaml @@ -1,6 +1,7 @@ processor: ignoreTypes: - "List$" + - "CommonStatus" ignoreFields: - "status$" - "TypeMeta$"