INNER CODE UNIT · Go
main
antrea-io/antrea · cmd/antrea-controller/main.go:30
func main() {
command := newControllerCommand()
if err := command.Execute(); err != nil {
os.Exit(1)
}
}
func newControllerCommand() *cobra.Command {
opts := newOptions()
cmd := &cobra.Command{
Use: "antrea-controller",
Long: "The Antrea Controller.",
Run: func(cmd *cobra.Command, args []string) {
log.InitLogs(cmd.Flags())
defer log.FlushLogs()
if err := opts.complete(); err != nil {
klog.Fatalf("Failed to complete: %v", err)