39 lines
633 B
Go
39 lines
633 B
Go
package main
|
|
|
|
import (
|
|
"os"
|
|
|
|
"git.sense-t.eu.org/ACE/ace/cmd/config"
|
|
"git.sense-t.eu.org/ACE/ace/cmd/server"
|
|
"github.com/sirupsen/logrus"
|
|
"github.com/urfave/cli/v2"
|
|
)
|
|
|
|
func init() {
|
|
logrus.SetReportCaller(true)
|
|
}
|
|
|
|
func main() {
|
|
app := &cli.App{
|
|
Name: "ace",
|
|
Usage: "cloud emulator",
|
|
Commands: []*cli.Command{
|
|
config.Command,
|
|
server.Command,
|
|
},
|
|
Flags: []cli.Flag{
|
|
&cli.StringFlag{
|
|
Name: "config",
|
|
Usage: "config file",
|
|
Aliases: []string{"c"},
|
|
EnvVars: []string{"ACE_CONFIG"},
|
|
Value: "config.yaml",
|
|
},
|
|
},
|
|
}
|
|
|
|
if err := app.Run(os.Args); err != nil {
|
|
logrus.Panic(err)
|
|
}
|
|
}
|