我将 vagrant 与 3rd 方 linux 盒一起使用。
该框具有默认的 vagrant/vagrant 凭据。
在我的 Vagrantfile 我希望它使用 ssh 所以我有这个
config.vm.provision :shell, :path => "bootstrap.sh"
config.ssh.private_key_path = "~/.ssh/id_rsa"
config.ssh.forward_agent = true
最佳答案
找到了有用的东西
基于此Vagrant insecure by default?
我们在哪里
config.ssh.private_key_path = ["#{ENV['HOME']}/.ssh/id_rsa", \
"#{ENV['HOME']}/.vagrant.d/insecure_private_key"]
关于ssh - vagrant ssh key 鸡和蛋,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24487927/