Commit d8cc24f8 authored by Mitchell Hashimoto's avatar Mitchell Hashimoto

builder/openstack: no more port

parent 5167c65f
......@@ -22,7 +22,7 @@ func CommHost(
// If we have a specific interface, try that
if sshinterface != "" {
if addr := sshAddrFromPool(s, sshinterface, port); addr != "" {
if addr := sshAddrFromPool(s, sshinterface); addr != "" {
return addr, nil
}
}
......@@ -38,7 +38,7 @@ func CommHost(
}
// Try to get it from the requested interface
if addr := sshAddrFromPool(s, sshinterface, port); addr != "" {
if addr := sshAddrFromPool(s, sshinterface); addr != "" {
return addr, nil
}
......@@ -75,7 +75,7 @@ func SSHConfig(username string) func(multistep.StateBag) (*ssh.ClientConfig, err
}
}
func sshAddrFromPool(s *servers.Server, desired string, port int) string {
func sshAddrFromPool(s *servers.Server, desired string) string {
// Get all the addresses associated with this server. This
// was taken directly from Terraform.
for pool, networkAddresses := range s.Addresses {
......@@ -106,7 +106,7 @@ func sshAddrFromPool(s *servers.Server, desired string, port int) string {
}
}
if addr != "" {
return fmt.Sprintf("%s:%d", addr, port)
return addr
}
}
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment