diff --git a/cmd/iam/createconnect/createconnect.go b/cmd/iam/createconnect/createconnect.go new file mode 100644 index 00000000..d42553fd --- /dev/null +++ b/cmd/iam/createconnect/createconnect.go @@ -0,0 +1,29 @@ +package createconnect + +import ( + "github.com/spf13/cobra" + "github.com/srinandan/apigeecli/cmd/shared" +) + +//Cmd to get org details +var Cmd = &cobra.Command{ + Use: "createconnect", + Short: "Create a new IAM Service Account for Apigee Connect", + Long: "Create a new IAM Service Account for Apigee Connect", + RunE: func(cmd *cobra.Command, args []string) (err error) { + return shared.CreateIAMServiceAccount(name, "connect") + }, +} + +var name string + +func init() { + + Cmd.Flags().StringVarP(&shared.RootArgs.ProjectID, "prj", "p", + "", "GCP Project ID") + Cmd.Flags().StringVarP(&name, "name", "n", + "", "Service Account Name") + + _ = Cmd.MarkFlagRequired("prj") + _ = Cmd.MarkFlagRequired("name") +}