diff --git a/api/v1alpha1/reservation_types.go b/api/v1alpha1/reservation_types.go index 97950a395..e0f141ebc 100644 --- a/api/v1alpha1/reservation_types.go +++ b/api/v1alpha1/reservation_types.go @@ -211,6 +211,16 @@ type ReservationStatus struct { // +kubebuilder:printcolumn:name="Type",type="string",JSONPath=".metadata.labels['reservations\\.cortex\\.cloud/type']" // +kubebuilder:printcolumn:name="Host",type="string",JSONPath=".status.host" // +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status" +// +kubebuilder:printcolumn:name="ResourceGroup",type="string",JSONPath=".spec.committedResourceReservation.resourceGroup" +// +kubebuilder:printcolumn:name="Project",type="string",JSONPath=".spec.committedResourceReservation.projectID" +// +kubebuilder:printcolumn:name="AZ",type="string",JSONPath=".spec.availabilityZone" +// +kubebuilder:printcolumn:name="StartTime",type="string",JSONPath=".spec.startTime",priority=1 +// +kubebuilder:printcolumn:name="EndTime",type="string",JSONPath=".spec.endTime" +// +kubebuilder:printcolumn:name="Resources",type="string",JSONPath=".spec.resources",priority=1 +// +kubebuilder:printcolumn:name="LastChanged",type="date",JSONPath=".status.failoverReservation.lastChanged",priority=1 +// +kubebuilder:printcolumn:name="AcknowledgedAt",type="date",JSONPath=".status.failoverReservation.acknowledgedAt",priority=1 +// +kubebuilder:printcolumn:name="CR Allocations",type="string",JSONPath=".status.committedResourceReservation.allocations",priority=1 +// +kubebuilder:printcolumn:name="HA Allocations",type="string",JSONPath=".status.failoverReservation.allocations",priority=1 // Reservation is the Schema for the reservations API type Reservation struct { diff --git a/helm/library/cortex/files/crds/cortex.cloud_reservations.yaml b/helm/library/cortex/files/crds/cortex.cloud_reservations.yaml index ab622c1c0..64931bc4d 100644 --- a/helm/library/cortex/files/crds/cortex.cloud_reservations.yaml +++ b/helm/library/cortex/files/crds/cortex.cloud_reservations.yaml @@ -24,6 +24,42 @@ spec: - jsonPath: .status.conditions[?(@.type=='Ready')].status name: Ready type: string + - jsonPath: .spec.committedResourceReservation.resourceGroup + name: ResourceGroup + type: string + - jsonPath: .spec.committedResourceReservation.projectID + name: Project + type: string + - jsonPath: .spec.availabilityZone + name: AZ + type: string + - jsonPath: .spec.startTime + name: StartTime + priority: 1 + type: string + - jsonPath: .spec.endTime + name: EndTime + type: string + - jsonPath: .spec.resources + name: Resources + priority: 1 + type: string + - jsonPath: .status.failoverReservation.lastChanged + name: LastChanged + priority: 1 + type: date + - jsonPath: .status.failoverReservation.acknowledgedAt + name: AcknowledgedAt + priority: 1 + type: date + - jsonPath: .status.committedResourceReservation.allocations + name: CR Allocations + priority: 1 + type: string + - jsonPath: .status.failoverReservation.allocations + name: HA Allocations + priority: 1 + type: string name: v1alpha1 schema: openAPIV3Schema: