Skip to content

Commit

Permalink
Add the Ready and Synced status indicators to output (#45)
Browse files Browse the repository at this point in the history
* Add the Ready and Synced status indicators to output

Signed-off-by: Bob Haddleton <[email protected]>

* Add the kubebuilder specs for the ready and synced output fields

Signed-off-by: Bob Haddleton <[email protected]>
  • Loading branch information
bobh66 committed Apr 6, 2022
1 parent 262445d commit 2addee0
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
2 changes: 2 additions & 0 deletions apis/v1alpha1/workspace_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,8 @@ type WorkspaceStatus struct {

// A Workspace of Terraform Configuration.
// +kubebuilder:subresource:status
// +kubebuilder:printcolumn:name="READY",type="string",JSONPath=".status.conditions[?(@.type=='Ready')].status"
// +kubebuilder:printcolumn:name="SYNCED",type="string",JSONPath=".status.conditions[?(@.type=='Synced')].status"
// +kubebuilder:printcolumn:name="AGE",type="date",JSONPath=".metadata.creationTimestamp"
// +kubebuilder:resource:scope=Cluster
type Workspace struct {
Expand Down
6 changes: 6 additions & 0 deletions package/crds/tf.crossplane.io_workspaces.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,12 @@ spec:
scope: Cluster
versions:
- additionalPrinterColumns:
- jsonPath: .status.conditions[?(@.type=='Ready')].status
name: READY
type: string
- jsonPath: .status.conditions[?(@.type=='Synced')].status
name: SYNCED
type: string
- jsonPath: .metadata.creationTimestamp
name: AGE
type: date
Expand Down

0 comments on commit 2addee0

Please sign in to comment.