enable grub boot for all nodes
Signed-off-by: Christian Goll <cgoll@suse.com>
This commit is contained in:
committed by
Jonathon Anderson
parent
03ef7447e9
commit
60dc8f6251
@@ -6,6 +6,9 @@ import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
/*
|
||||
get node by its hardware/MAC address, return error otherwise
|
||||
*/
|
||||
func (config *NodeYaml) FindByHwaddr(hwa string) (NodeInfo, error) {
|
||||
if _, err := net.ParseMAC(hwa); err != nil {
|
||||
return NodeInfo{}, errors.New("invalid hardware address: " + hwa)
|
||||
@@ -26,6 +29,9 @@ func (config *NodeYaml) FindByHwaddr(hwa string) (NodeInfo, error) {
|
||||
return ret, errors.New("No nodes found with HW Addr: " + hwa)
|
||||
}
|
||||
|
||||
/*
|
||||
get node by its ip address, return error otherwise
|
||||
*/
|
||||
func (config *NodeYaml) FindByIpaddr(ipaddr string) (NodeInfo, error) {
|
||||
if addr := net.ParseIP(ipaddr); addr == nil {
|
||||
return NodeInfo{}, errors.New("invalid IP:" + ipaddr)
|
||||
|
||||
Reference in New Issue
Block a user