From bacfb021828fec7672420344dadefbccf9b35ef2 Mon Sep 17 00:00:00 2001 From: Adrien Delorme Date: Wed, 22 Aug 2018 18:16:25 +0200 Subject: [PATCH] doc better SSHConfigFunc --- helper/communicator/config.go | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/helper/communicator/config.go b/helper/communicator/config.go index ad6a63989..4a9b97f77 100644 --- a/helper/communicator/config.go +++ b/helper/communicator/config.go @@ -91,14 +91,18 @@ func (c *Config) SSHConfigFunc() func(multistep.StateBag) (*ssh.ClientConfig, er } privateKeys = append(privateKeys, bytes) } + + // aws,alicloud,cloudstack,digitalOcean,oneAndOne,openstack,oracle & profitbricks key if iKey, hasKey := state.GetOk("privateKey"); hasKey { privateKeys = append(privateKeys, []byte(iKey.(string))) } - if iKey, hasKey := state.GetOk("ssh_private_key"); hasKey { // gcp key + // gcp key + if iKey, hasKey := state.GetOk("ssh_private_key"); hasKey { privateKeys = append(privateKeys, []byte(iKey.(string))) } - //this is what scaleway.sshConfig did + + //scaleway key if iKey, hasKey := state.GetOk("private_key"); hasKey { privateKeys = append(privateKeys, []byte(iKey.(string))) }