|
|
@ -14,6 +14,8 @@ type Profile struct {
|
|
|
|
Name string
|
|
|
|
Name string
|
|
|
|
// Path to binary to launch
|
|
|
|
// Path to binary to launch
|
|
|
|
Path string
|
|
|
|
Path string
|
|
|
|
|
|
|
|
// Path of the config file
|
|
|
|
|
|
|
|
ConfigPath string `json:"-"`
|
|
|
|
// Optional path of binary to watch for watchdog purposes if different than Path
|
|
|
|
// Optional path of binary to watch for watchdog purposes if different than Path
|
|
|
|
Watchdog string
|
|
|
|
Watchdog string
|
|
|
|
// Optional wrapper binary to use when launching command (ex: tsocks)
|
|
|
|
// Optional wrapper binary to use when launching command (ex: tsocks)
|
|
|
@ -151,5 +153,6 @@ func loadProfileFile(file string) (*Profile, error) {
|
|
|
|
if p.Name == "" {
|
|
|
|
if p.Name == "" {
|
|
|
|
p.Name = path.Base(p.Path)
|
|
|
|
p.Name = path.Base(p.Path)
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
p.ConfigPath = file
|
|
|
|
return p, nil
|
|
|
|
return p, nil
|
|
|
|
}
|
|
|
|
}
|
|
|
|