Skip to content

Commit

Permalink
Merge pull request #198 from slintes/backport_no_mandatory_status_fields
Browse files Browse the repository at this point in the history
[release-0.4] Don't have mandatory fields in status
  • Loading branch information
slintes authored Apr 12, 2023
2 parents a0fe1c5 + 982d43a commit a9da8c0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 14 deletions.
8 changes: 4 additions & 4 deletions api/v1alpha1/nodehealthcheck_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,13 +120,13 @@ type UnhealthyCondition struct {
type NodeHealthCheckStatus struct {
// +operator-sdk:csv:customresourcedefinitions:type=status,displayName="observedNodes",xDescriptors="urn:alm:descriptor:com.tectonic.ui:observedNodes"
//ObservedNodes specified the number of nodes observed by using the NHC spec.selector
// +kubebuilder:default:=0
ObservedNodes int `json:"observedNodes"`
//+optional
ObservedNodes int `json:"observedNodes,omitempty"`

// +operator-sdk:csv:customresourcedefinitions:type=status,displayName="healthynodes",xDescriptors="urn:alm:descriptor:com.tectonic.ui:healthyNodes"
//HealthyNodes specified the number of healthy nodes observed
// +kubebuilder:default:=0
HealthyNodes int `json:"healthyNodes"`
//+optional
HealthyNodes int `json:"healthyNodes,omitempty"`

// +operator-sdk:csv:customresourcedefinitions:type=status,displayName="inFlightRemediations",xDescriptors="urn:alm:descriptor:com.tectonic.ui:inFlightRemediations"
//InFlightRemediations records the timestamp when remediation triggered per node
Expand Down
5 changes: 0 additions & 5 deletions bundle/manifests/remediation.medik8s.io_nodehealthchecks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,6 @@ spec:
- type
x-kubernetes-list-type: map
healthyNodes:
default: 0
description: HealthyNodes specified the number of healthy nodes observed
type: integer
inFlightRemediations:
Expand All @@ -273,7 +272,6 @@ spec:
triggered per node
type: object
observedNodes:
default: 0
description: ObservedNodes specified the number of nodes observed
by using the NHC spec.selector
type: integer
Expand All @@ -286,9 +284,6 @@ spec:
reason:
description: Reason explains the current phase in more detail.
type: string
required:
- healthyNodes
- observedNodes
type: object
type: object
served: true
Expand Down
5 changes: 0 additions & 5 deletions config/crd/bases/remediation.medik8s.io_nodehealthchecks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,6 @@ spec:
- type
x-kubernetes-list-type: map
healthyNodes:
default: 0
description: HealthyNodes specified the number of healthy nodes observed
type: integer
inFlightRemediations:
Expand All @@ -272,7 +271,6 @@ spec:
triggered per node
type: object
observedNodes:
default: 0
description: ObservedNodes specified the number of nodes observed
by using the NHC spec.selector
type: integer
Expand All @@ -285,9 +283,6 @@ spec:
reason:
description: Reason explains the current phase in more detail.
type: string
required:
- healthyNodes
- observedNodes
type: object
type: object
served: true
Expand Down

0 comments on commit a9da8c0

Please sign in to comment.