communicators/ssh: output UI when inserting key
This commit is contained in:
parent
074bb2c7fb
commit
54e640b0c9
|
@ -60,6 +60,7 @@ module VagrantPlugins
|
|||
ssh_info = @machine.ssh_info
|
||||
if ssh_info[:password] && ssh_info[:private_key_path].empty?
|
||||
@logger.info("Inserting insecure key to avoid password")
|
||||
@machine.ui.info(I18n.t("vagrant.inserting_insecure_key"))
|
||||
@machine.guest.capability(
|
||||
:insert_public_key,
|
||||
Vagrant.source_root.join("keys", "vagrant.pub").read)
|
||||
|
@ -70,7 +71,7 @@ module VagrantPlugins
|
|||
f.write(Vagrant.source_root.join("keys", "vagrant").read)
|
||||
end
|
||||
|
||||
@logger.info("Disconecting SSH so we can reconnect with new SSH key")
|
||||
@machine.ui.info(I18n.t("vagrant.inserted_key"))
|
||||
@connection.close
|
||||
@connection = nil
|
||||
|
||||
|
|
|
@ -58,6 +58,10 @@ en:
|
|||
docker_install_with_version_not_supported: |-
|
||||
Vagrant is not capable of installing an specific version of Docker
|
||||
onto the guest machine and the latest version will be installed.
|
||||
inserted_key: |-
|
||||
Key inserted! Disconnecting and reconnecting using new SSH key...
|
||||
inserting_insecure_key: |-
|
||||
Inserting Vagrant public key within guest...
|
||||
plugin_needs_reinstall: |-
|
||||
The following plugins were installed with a version of Vagrant
|
||||
that had different versions of underlying components. Because
|
||||
|
|
Loading…
Reference in New Issue