Merge pull request #400 from jcsiadal/netdevfix
Fix wwctl bug deleting networks and ability to set default network
This commit is contained in:
@@ -75,7 +75,7 @@ type NetDevs struct {
|
||||
Prefix string `yaml:"prefix,omitempty"`
|
||||
Netmask string `yaml:"netmask,omitempty"`
|
||||
Gateway string `yaml:"gateway,omitempty"`
|
||||
Default string `yaml:"default,omitempty"`
|
||||
Default string `yaml:"primary,omitempty"`
|
||||
Tags map[string]string `yaml:"tags,omitempty"`
|
||||
}
|
||||
|
||||
|
||||
@@ -68,6 +68,8 @@ Set bool
|
||||
func (ent *Entry) SetB(val bool) {
|
||||
if val {
|
||||
ent.value = []string{"true"}
|
||||
} else {
|
||||
ent.value = []string{"false"}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,6 +102,9 @@ func (ent *Entry) SetAltB(val bool, from string) {
|
||||
if val {
|
||||
ent.altvalue = []string{"true"}
|
||||
ent.from = from
|
||||
} else {
|
||||
ent.altvalue = []string{"false"}
|
||||
ent.from = from
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user