File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -117,6 +117,8 @@ func CmdList() *cobra.Command {
117117 Run : RunList ,
118118 Args : cobra .NoArgs ,
119119 }
120+ cmd .Flags ().Bool ("local-obc-only" , false ,
121+ "List only local OBCs (exclude remote OBCs created for client clusters)" )
120122 return cmd
121123}
122124
@@ -497,6 +499,7 @@ func RunStatus(cmd *cobra.Command, args []string) {
497499
498500// RunList runs a CLI command
499501func RunList (cmd * cobra.Command , args []string ) {
502+ localObcOnly , _ := cmd .Flags ().GetBool ("local-obc-only" )
500503 list := & nbv1.ObjectBucketClaimList {
501504 TypeMeta : metav1.TypeMeta {Kind : "ObjectBucketClaim" },
502505 }
@@ -521,7 +524,7 @@ func RunList(cmd *cobra.Command, args []string) {
521524 obc := & list .Items [i ]
522525
523526 // Do not show remote OBCs in the list (OBCs that were created for client clusters)
524- if util .IsRemoteObcAnnotation (obc .Annotations ) {
527+ if localObcOnly && util .IsRemoteObcAnnotation (obc .Annotations ) {
525528 countRemoteOBCs ++
526529 continue
527530 }
You can’t perform that action at this time.
0 commit comments