Skip to content

Commit

Permalink
add image and storage to display when get obclsuter resource using ku…
Browse files Browse the repository at this point in the history
…bectl -o wide
  • Loading branch information
chris-sun-star committed Nov 18, 2024
1 parent 10f133c commit 09bf40e
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 5 deletions.
4 changes: 3 additions & 1 deletion api/v1alpha1/obcluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,10 @@ type OBClusterStatus struct {
//+kubebuilder:object:root=true
//+kubebuilder:subresource:status
//+kubebuilder:printcolumn:name="Status",type="string",JSONPath=".status.status"
//+kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"
//+kubebuilder:printcolumn:name="ClusterName",type="string",JSONPath=".spec.clusterName"
//+kubebuilder:printcolumn:name="Age",type="date",JSONPath=".metadata.creationTimestamp"
//+kubebuilder:printcolumn:name="Image",type="string",JSONPath=".spec.observer.image",priority=1
//+kubebuilder:printcolumn:name="Storage",type="string",JSONPath=".spec.observer.storage",priority=1
//+kubebuilder:printcolumn:name="Tasks",type="string",JSONPath=".status.operationContext.tasks",priority=1
//+kubebuilder:printcolumn:name="Task",type="string",JSONPath=".status.operationContext.task",priority=1

Expand Down
12 changes: 10 additions & 2 deletions config/crd/bases/oceanbase.oceanbase.com_obclusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,19 @@ spec:
- jsonPath: .status.status
name: Status
type: string
- jsonPath: .spec.clusterName
name: ClusterName
type: string
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- jsonPath: .spec.clusterName
name: ClusterName
- jsonPath: .spec.observer.image
name: Image
priority: 1
type: string
- jsonPath: .spec.observer.storage
name: Storage
priority: 1
type: string
- jsonPath: .status.operationContext.tasks
name: Tasks
Expand Down
12 changes: 10 additions & 2 deletions deploy/operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6792,11 +6792,19 @@ spec:
- jsonPath: .status.status
name: Status
type: string
- jsonPath: .spec.clusterName
name: ClusterName
type: string
- jsonPath: .metadata.creationTimestamp
name: Age
type: date
- jsonPath: .spec.clusterName
name: ClusterName
- jsonPath: .spec.observer.image
name: Image
priority: 1
type: string
- jsonPath: .spec.observer.storage
name: Storage
priority: 1
type: string
- jsonPath: .status.operationContext.tasks
name: Tasks
Expand Down

0 comments on commit 09bf40e

Please sign in to comment.