当我运行游走程序并在配置类型中使用rsync方法时,我得到了以下错误
There was an error when attempting to rsync a synced folder.
Please inspect the error message below for more info.
Host path: /e/virtual-boxes/scotchbox/
Guest path: /var/www
Command: rsync --verbose --archive --delete -z --copy-links --chmod=ugo=rwX --no-perms --no-owner --no-group --rsync-path sudo rsync -e ssh -p 2222 -o StrictHostKeyChecking=no -o IdentitiesOnly=true -o UserKnownHostsFile=/dev/null -i 'E:/virtual-boxes/scotchbox/.vagrant/machines/default/virtualbox/private_key' --exclude .vagrant/ --exclude .git/ /e/virtual-boxes/scotchbox/ vagrant@127.0.0.1:/var/www
Error: Warning: Permanently added '[127.0.0.1]:2222' (ECDSA) to the list of known hosts.
dup() in/out/err failed
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(226) [sender=3.1.1]发布于 2016-03-30 03:44:22
我从Google找到了解决方案,当使用rsync方法时,然后将ssh帐户添加到Vagrantfile内容:
config.ssh.username = "vagrant"
config.ssh.password = "vagrant"
config.vm.synced_folder ".", "/var/www", type: "rsync", rsync__exclude: ".git/"并在C:\HashiCorp\Vagrant\embedded\gems\gems\vagrant-xxx\plugins\synced_folders\sync\helper.rb文件中删除77 ~ 79行
"-o ControlMaster=auto " +
"-o ControlPath=#{controlpath} " +
"-o ControlPersist=10m " +https://stackoverflow.com/questions/36251364
复制相似问题