Adrien Delorme 41f6e0334d refactor all copy pasted sshConfig with into communicator.Config.SSHConfigFunc
* still need to append the auth methods into an array for gracefullness
2018-08-22 17:02:23 +02:00

18 lines
328 B
Go

package triton
import (
"github.com/hashicorp/packer/helper/multistep"
)
func commHost(state multistep.StateBag) (string, error) {
driver := state.Get("driver").(Driver)
machineID := state.Get("machine").(string)
machine, err := driver.GetMachineIP(machineID)
if err != nil {
return "", err
}
return machine, nil
}