INNER CODE UNIT · Go

main

cri-o/cri-o · contrib/metrics-exporter/main.go:26

func main() {
	if err := run(); err != nil {
		logrus.Fatalf("Unable to run: %v", err)
	}
}

func run() error {
	logrus.SetFormatter(&logrus.TextFormatter{DisableTimestamp: true})

	logrus.Info("Getting cluster configuration")

	config, err := rest.InClusterConfig()
	if err != nil {
		return fmt.Errorf("retrieving client config: %w", err)
	}

	logrus.Info("Creating Kubernetes client")

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…