Skip to content

Commit

Permalink
Merge pull request #1184 from subutai-io/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
crioto authored Dec 4, 2018
2 parents a8e64ec + 2ea1ad3 commit 2903486
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/p2p.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,8 @@ func (p *PeerToPeer) PrepareInterfaces(ip, interfaceName string) error {
return fmt.Errorf("Interface is already in use")
}

if ip == "dhcp" {
if ip == "dhcp" || ip == "auto" {
ip = "dhcp"
ipn, maskn, err := p.RequestIP(p.Interface.GetHardwareAddress().String(), iface)
if err != nil {
return err
Expand All @@ -305,7 +306,7 @@ func (p *PeerToPeer) PrepareInterfaces(ip, interfaceName string) error {
p.Interface.SetIP(ipn)
p.Interface.SetMask(maskn)
return nil
} else if ip == "auto" {
} else if ip == "discover" {
p.Interface.SetAuto(true)
p.Interface.SetIP(nil)
p.Interface.SetSubnet(nil)
Expand Down

0 comments on commit 2903486

Please sign in to comment.