paramters in node

This commit is contained in:
Niko Kivel
2021-05-08 19:04:37 +02:00
parent 37556e6a64
commit dd4c075f50
6 changed files with 51 additions and 0 deletions

View File

@@ -41,6 +41,8 @@ var (
SetDiscoverable bool
SetUndiscoverable bool
SetRoot string
SetParam string
SetValue string
)
func init() {
@@ -74,6 +76,9 @@ func init() {
baseCmd.PersistentFlags().BoolVar(&SetNetDevDel, "netdel", false, "Delete the node's network device")
baseCmd.PersistentFlags().BoolVar(&SetNetDevDefault, "netdefault", false, "Set this network to be default")
baseCmd.PersistentFlags().StringVarP(&SetParam, "param", "p", "", "Define custom parameter")
baseCmd.PersistentFlags().StringVarP(&SetValue, "value", "", "", "Set custom parameter value")
baseCmd.PersistentFlags().BoolVarP(&SetNodeAll, "all", "a", false, "Set all nodes")
baseCmd.PersistentFlags().BoolVarP(&SetYes, "yes", "y", false, "Set 'yes' to all questions asked")