Documentation ¶
Index ¶
- Variables
- func ConfigTx(configs map[string]*config.NodeConfig, ctx *helpers.Context) error
- func ConfigTx1(c *config.NodeConfig, action tx.Action) ([]*tx.Response, error)
- func ConfigTx1PP(ctx *helpers.Context, act tx.Action, nn string, cfg *config.NodeConfig)
- func DiscoverFile(template, infile string) ([]map[string]interface{}, error)
- func DiscoverTopo(templateName string, ctx *helpers.Context) (map[string][]map[string]interface{}, error)
- func GetCmdLineParser(ast interface{}) *kong.Kong
- func LoadAndPrep(nodeFilter *[]string, topoFile string, render bool) (map[string]*config.NodeConfig, error)
- func Main()
- func RunWebConfig(ws chan<- interface{}, cmd string)
- func WebConfigDone(ws chan<- interface{}, retry int)
- type CmdColor
- type CmdConfig
- type CmdServe
- type CmdVersion
Constants ¶
This section is empty.
Variables ¶
View Source
var Ctx *helpers.Context
App wide context
Functions ¶
func ConfigTx1PP ¶ added in v0.0.12
func DiscoverFile ¶
func DiscoverTopo ¶
func GetCmdLineParser ¶ added in v0.0.3
func LoadAndPrep ¶
func LoadAndPrep(nodeFilter *[]string, topoFile string, render bool) (map[string]*config.NodeConfig, error)
Load the topo files and prepare the variables
func RunWebConfig ¶ added in v0.0.3
func RunWebConfig(ws chan<- interface{}, cmd string)
func WebConfigDone ¶ added in v0.0.8
func WebConfigDone(ws chan<- interface{}, retry int)
Types ¶
type CmdConfig ¶
type CmdConfig struct { Topo string `short:"t" help:"topology file" type:"existingfile" predictor:"topo"` TemplatePaths []string `short:"p" help:"paths to search for templates" type:"existingdir" predictor:"dir"` TemplateList []string `short:"l" help:"template names to render"` Filter []string `short:"f" help:"nodes to include" optional:""` Commit struct{} `cmd:"" help:"Commit configuration on the node."` Compare struct{} `cmd:"" help:"Compare rendered templates to the node's config."` Send struct{} `cmd:"" help:"Send commands to the node (i.e. show)"` Template struct{} `cmd:"" help:"Show rendered templates."` Vars struct{} `cmd:"" help:"Show variable inputs."` }
type CmdServe ¶
type CmdServe struct { Topo string `short:"t" help:"Topology file" type:"existingfile" predictor:"topo"` TemplatePaths []string `short:"p" help:"Paths to search for templates" type:"path" predictor:"dir"` Addr string `help:"Serve on addr." default:":8080"` Url string `help:"Serve on a custom URL path" default:"/labctl"` }
type CmdVersion ¶ added in v0.0.5
type CmdVersion struct {
Upgrade bool `short:"u" help:"Upgrade labctl" default:"false"`
}
Click to show internal directories.
Click to hide internal directories.