lobby2/cli/main.go
Adam Štrauch ae6ca5c185
All checks were successful
Tests / test (push) Successful in 12s
Support for Prometheus SD
2024-12-22 13:40:50 +01:00

42 lines
637 B
Go

package main
import (
"log"
"os"
"github.com/urfave/cli/v2"
)
func main() {
app := &cli.App{
Name: "",
Usage: "",
Commands: []*cli.Command{
{
Name: "master",
Usage: "Runs master node API",
Action: masterAction,
},
{
Name: "node",
Usage: "Runs node on local machine",
Action: nodeAction,
},
{
Name: "print",
Usage: "Prints all discovered nodes",
Action: printAction,
},
{
Name: "prometheus",
Usage: "Prints Prometheus Service Discovery",
Action: prometheusAction,
},
},
}
err := app.Run(os.Args)
if err != nil {
log.Fatal(err)
}
}