2019-01-01 08:23:01 +00:00
|
|
|
//go:generate go run types/codegen/cleanup/main.go
|
|
|
|
//go:generate go run types/codegen/main.go
|
2019-01-24 17:51:14 +00:00
|
|
|
//go:generate go fmt pkg/deploy/zz_generated_bindata.go
|
2019-01-26 04:56:12 +00:00
|
|
|
//go:generate go fmt pkg/openapi/zz_generated_bindata.go
|
2019-01-01 08:23:01 +00:00
|
|
|
|
|
|
|
package main
|
|
|
|
|
|
|
|
import (
|
|
|
|
"os"
|
|
|
|
|
2019-01-09 16:54:15 +00:00
|
|
|
"github.com/rancher/k3s/pkg/cli/agent"
|
|
|
|
"github.com/rancher/k3s/pkg/cli/cmds"
|
|
|
|
"github.com/rancher/k3s/pkg/cli/kubectl"
|
|
|
|
"github.com/rancher/k3s/pkg/cli/server"
|
2019-01-01 08:23:01 +00:00
|
|
|
"github.com/sirupsen/logrus"
|
|
|
|
"github.com/urfave/cli"
|
|
|
|
)
|
|
|
|
|
|
|
|
func main() {
|
2019-01-09 16:54:15 +00:00
|
|
|
app := cmds.NewApp()
|
2019-01-01 08:23:01 +00:00
|
|
|
app.Commands = []cli.Command{
|
2019-01-09 16:54:15 +00:00
|
|
|
cmds.NewServerCommand(server.Run),
|
|
|
|
cmds.NewAgentCommand(agent.Run),
|
|
|
|
cmds.NewKubectlCommand(kubectl.Run),
|
2019-01-01 08:23:01 +00:00
|
|
|
}
|
|
|
|
|
2019-01-09 16:54:15 +00:00
|
|
|
if err := app.Run(os.Args); err != nil {
|
2019-01-01 08:23:01 +00:00
|
|
|
logrus.Fatal(err)
|
|
|
|
}
|
|
|
|
}
|