Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ClientCommand = &cli.Command{ Name: "client", Usage: "NodeISP Management Client", Action: func(ctx context.Context, cmd *cli.Command) error { return client.Run() }, }
View Source
var ConfigFlag = &cli.StringFlag{ Name: "config", Aliases: []string{"c"}, Usage: "Load configuration from `FILE`", Sources: cli.EnvVars("NODEISP_CONFIG"), Value: "/etc/node-isp/config.yaml", Destination: &config.File, }
View Source
var RootCommand = &cli.Command{ Name: "node-isp", Usage: "Building blocks for your own ISP", Version: version.Version, Flags: []cli.Flag{ ConfigFlag, }, Commands: []*cli.Command{ SetupCommand, ServerCommand, ClientCommand, }, }
View Source
var ServerCommand = &cli.Command{ Name: "server", Usage: "NodeISP Server", Action: func(ctx context.Context, cmd *cli.Command) error { _, err := os.Stat(config.File) if os.IsNotExist(err) { c := SetupCommand c.Flags = append(c.Flags, ConfigFlag) return SetupCommand.Run(ctx, os.Args) } return server.Run() }, }
Functions ¶
This section is empty.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.