-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathmongodbflex.go
32 lines (28 loc) · 1005 Bytes
/
mongodbflex.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
package mongodbflex
import (
"github.com/stackitcloud/stackit-cli/internal/cmd/mongodbflex/backup"
"github.com/stackitcloud/stackit-cli/internal/cmd/mongodbflex/instance"
"github.com/stackitcloud/stackit-cli/internal/cmd/mongodbflex/options"
"github.com/stackitcloud/stackit-cli/internal/cmd/mongodbflex/user"
"github.com/stackitcloud/stackit-cli/internal/pkg/args"
"github.com/stackitcloud/stackit-cli/internal/pkg/print"
"github.com/stackitcloud/stackit-cli/internal/pkg/utils"
"github.com/spf13/cobra"
)
func NewCmd(p *print.Printer) *cobra.Command {
cmd := &cobra.Command{
Use: "mongodbflex",
Short: "Provides functionality for MongoDB Flex",
Long: "Provides functionality for MongoDB Flex.",
Args: args.NoArgs,
Run: utils.CmdHelp,
}
addSubcommands(cmd, p)
return cmd
}
func addSubcommands(cmd *cobra.Command, p *print.Printer) {
cmd.AddCommand(instance.NewCmd(p))
cmd.AddCommand(user.NewCmd(p))
cmd.AddCommand(options.NewCmd(p))
cmd.AddCommand(backup.NewCmd(p))
}