Skip to content

Commit

Permalink
Merge pull request #33 from liath/fix-xen-tools-ip-resolution
Browse files Browse the repository at this point in the history
Fix XenServer tools guest IP address resolution
  • Loading branch information
ddelnano authored Dec 19, 2021
2 parents 5525b73 + 509b6b3 commit f4a161e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion builder/xenserver/common/step_wait_for_ip.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ func (self *StepWaitForIP) Run(ctx context.Context, state multistep.StateBag) mu
return false, err
}
networks := metrics.Networks
if ip, ok := networks["0/ip"]; ok {
var ok bool
if ip, ok = networks["0/ip"]; ok {
if ip != "" {
ui.Message(fmt.Sprintf("Got IP '%s' from XenServer tools", ip))
return true, nil
Expand Down

0 comments on commit f4a161e

Please sign in to comment.