I want to copy a local file from a Vagrant machine to my localhost, but I am getting an error message:
localhost
ssh: connect to host 127.0.0.1>
127.0.0.1>
Get IdentityFile and Port by using
vagrant ssh-config
scp -i IdentityFile_file -P Port vagrant@127.0.0.1:/file_dir dist_dir e.g.
scp -i IdentityFile_file -P Port vagrant@127.0.0.1:/file_dir dist_dir
scp -i /Users/xxxxx/tmp/vagrant/centos_6.5/.vagrant/machines/default/virtualbox/private_key -P 2200 vagrant@127.0.0.1:/tmp/xxx .