问题描述
我已经很接近启动实例来在WSL2上测试Vagrant了,但是我继续遇到这个问题,当我运行vagrant up
时会出现以下错误:
app1: SSH address: 127.0.0.1:2200
app1: SSH username: vagrant
app1: SSH auth method: private key
app1: Warning: Connection refused. retrying...
app1: Warning: Connection refused. retrying...
app1: Warning: Connection refused. retrying...
这是我的Vagrantfile代码:
# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.Box = "generic/ubuntu1804"
config.ssh.forward_agent = true
config.ssh.forward_agent = true
config.vm.synced_folder ".","/vagrant",disabled: true
config.vm.provider :virtualBox do |v|
v.memory = 512
v.linked_clone = true
end
# Application server 1
config.vm.define "app1" do |app|
app.vm.hostname = "orc-app1.test"
app.vm.network :private_network,ip: "192.168.60.4"
end
# Application server 2
config.vm.define "app2" do |app|
app.vm.hostname = "orc-app2.test"
app.vm.network :private_network,ip: "192.168.60.5"
end
# Database server
config.vm.define "db" do |db|
db.vm.hostname = "orc-db.test"
db.vm.network :private_network,ip: "192.168.60.6"
end
end
我删除了rm insecure_private_key
和ran vagrant up
,以便它可以重新创建insecure_private_key,但错误仍然存在。
对此表示感谢。感觉完全转向Linux:)
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)