Skip to content

Commit

Permalink
fix duplicate machine pool information printed for the same cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
ThirumlaDevi committed Sep 25, 2023
1 parent 55cf5e9 commit 1f2b39b
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions cmd/ocm/list/machinepool/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,15 +99,7 @@ func run(cmd *cobra.Command, argv []string) error {
writer := tabwriter.NewWriter(os.Stdout, 0, 0, 2, ' ', 0)

fmt.Fprintf(writer, "ID\tAUTOSCALING\tREPLICAS\tINSTANCE TYPE\tLABELS\t\tTAINTS\t\tAVAILABILITY ZONES\n")
fmt.Fprintf(writer, "%s\t%s\t%s\t%s\t%s\t\t%s\t\t%s\n",
"default",
printAutoscaling(cluster.Nodes().AutoscaleCompute()),
printReplicas(cluster.Nodes().AutoscaleCompute(), cluster.Nodes().Compute()),
cluster.Nodes().ComputeMachineType().ID(),
printLabels(cluster.Nodes().ComputeLabels()),
"",
printAZ(cluster.Nodes().AvailabilityZones()),
)

for _, machinePool := range machinePools {
fmt.Fprintf(writer, "%s\t%s\t%s\t%s\t%s\t\t%s\t\t%s\n",
machinePool.ID(),
Expand Down

0 comments on commit 1f2b39b

Please sign in to comment.