I am new with virtual machine. I want to copy a file from host (Mac) to vagrant virtual machine. I could not share a folder, so I want to use command line. How can I copy a file from host to vagrant virtual machine with command line?
To copy a file from the host to vagrant:
scp -P 2222 /path/to/file vagrant@127.0.0.1:.
To copy a file from vagrant to host machine:
scp -P 2222 vagrant@127.0.0.1:/path/to/file