-
Notifications
You must be signed in to change notification settings - Fork 72
/
acl.go
32 lines (28 loc) · 1.06 KB
/
acl.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 acl
import (
"github.com/redhat-developer/app-services-cli/pkg/cmd/kafka/acl/admin"
"github.com/redhat-developer/app-services-cli/pkg/cmd/kafka/acl/create"
"github.com/redhat-developer/app-services-cli/pkg/cmd/kafka/acl/delete"
"github.com/redhat-developer/app-services-cli/pkg/cmd/kafka/acl/grant"
"github.com/redhat-developer/app-services-cli/pkg/cmd/kafka/acl/list"
"github.com/redhat-developer/app-services-cli/pkg/shared/factory"
"github.com/spf13/cobra"
)
// NewAclCommand creates a new command sub-group for Kafka ACL operations
func NewAclCommand(f *factory.Factory) *cobra.Command {
cmd := &cobra.Command{
Use: "acl",
Short: f.Localizer.MustLocalize("kafka.acl.cmd.shortDescription"),
Long: f.Localizer.MustLocalize("kafka.acl.cmd.longDescription"),
Example: f.Localizer.MustLocalize("kafka.acl.cmd.example"),
Args: cobra.ExactArgs(1),
}
cmd.AddCommand(
list.NewListACLCommand(f),
grant.NewGrantPermissionsACLCommand(f),
delete.NewDeleteCommand(f),
admin.NewAdminACLCommand(f),
create.NewCreateCommand(f),
)
return cmd
}