-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmain.go
More file actions
36 lines (29 loc) · 704 Bytes
/
main.go
File metadata and controls
36 lines (29 loc) · 704 Bytes
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
33
34
35
36
package main
import (
"context"
"fmt"
"os"
"rootcause/cmd/rootcause/cli"
"rootcause/pkg/server"
_ "rootcause/toolsets/aws"
_ "rootcause/toolsets/browser"
_ "rootcause/toolsets/helm"
_ "rootcause/toolsets/istio"
_ "rootcause/toolsets/k8s"
_ "rootcause/toolsets/karpenter"
_ "rootcause/toolsets/linkerd"
_ "rootcause/toolsets/rootcause"
_ "rootcause/toolsets/terraform"
)
const version = "0.1.0"
var runServer = server.Run
var exit = os.Exit
func main() {
if err := executeRoot(context.Background()); err != nil {
fmt.Fprintf(os.Stderr, "%v\n", err)
exit(1)
}
}
func executeRoot(ctx context.Context) error {
return cli.Execute(ctx, os.Args[1:], runServer, version, os.Stderr)
}