I want to copy a local file from a Vagrant machine to my localhost
, but I am getting an error message:
ssh: connect to host
127.0.0.1
Another option like Dan linked to:
vagrant plugin install vagrant-scp
vagrant scp [vm_name]:<remote_path> <local_path
and if you need to do the opposite its
vagrant scp <local_path> [vm_name]:<remote_path>
You can use vagrant status
to get the name of the VM
Current machine states:
default running (virtualbox)
Where default is the name of the VM in my case.