mirror of
https://github.com/psviderski/uncloud.git
synced 2026-08-27 11:33:33 +00:00
add service rm CLI command
This commit is contained in:
@@ -21,7 +21,7 @@ func NewListCommand() *cobra.Command {
|
||||
Short: "List machines in a cluster.",
|
||||
RunE: func(cmd *cobra.Command, args []string) error {
|
||||
uncli := cmd.Context().Value("cli").(*cli.CLI)
|
||||
return runList(cmd.Context(), uncli, cluster)
|
||||
return list(cmd.Context(), uncli, cluster)
|
||||
},
|
||||
}
|
||||
cmd.Flags().StringVarP(
|
||||
@@ -31,7 +31,7 @@ func NewListCommand() *cobra.Command {
|
||||
return cmd
|
||||
}
|
||||
|
||||
func runList(ctx context.Context, uncli *cli.CLI, clusterName string) error {
|
||||
func list(ctx context.Context, uncli *cli.CLI, clusterName string) error {
|
||||
client, err := uncli.ConnectCluster(ctx, clusterName)
|
||||
if err != nil {
|
||||
return fmt.Errorf("connect to cluster: %w", err)
|
||||
|
||||
Reference in New Issue
Block a user