From d8cc24f86ec902a4e498566b852aebe2eaea8b2e Mon Sep 17 00:00:00 2001 From: Mitchell Hashimoto Date: Mon, 15 Jun 2015 09:34:35 -0700 Subject: [PATCH] builder/openstack: no more port --- builder/openstack/ssh.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/builder/openstack/ssh.go b/builder/openstack/ssh.go index 7ec1fcfdd..3e7350d11 100644 --- a/builder/openstack/ssh.go +++ b/builder/openstack/ssh.go @@ -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 } } }