INNER CODE UNIT · Go
main
aws/amazon-vpc-cni-k8s · cmd/cni-metrics-helper/main.go:63
func main() {
// Do not add anything before initializing logger
logLevel := logger.GetLogLevel()
logConfig := logger.Configuration{
LogLevel: logLevel,
LogLocation: "stdout",
}
log := logger.New(&logConfig)
// Initialize controller-runtime logger
ctrl.SetLogger(logConfig.NewControllerRuntimeLogger())
options := &options{}
flags := pflag.NewFlagSet("", pflag.ExitOnError)
flags.AddGoFlagSet(flag.CommandLine)
flags.BoolVar(&options.submitCW, "cloudwatch", true, "a bool")
flags.BoolVar(&options.submitPrometheus, "prometheus metrics", false, "a bool")