Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Laravel and Vagrant: Don't have /home/vagrant folder

I've successfully created a laravel app with the $ laravel new blog command on my Ubuntu 16.04. All app files are located at the ~/Code folder.

Here's my Homestead.yaml file:

---
ip: "192.168.10.10"
memory: 2048
cpus: 1
provider: virtualbox

authorize: ~/.ssh/id_rsa.pub

keys:
    - ~/.ssh/id_rsa

folders:
    - map: ~/Code
      to: /home/vagrant/Code

sites:
    - map: devbase.app
      to: /home/vagrant/Code/blog/public

databases:
    - homestead 

The problem is I don't have this /home/vagrant folder on my computer. And, of course, the blog app source files are not shared to this folder.

Do I have to manually create this folder? And how to make the ~/Code folder share files with it then?

Or there occurred a problem while installing VirtualBox, Vagrant or Homestead?

What I have to do to make it work properly?

like image 259
9Algorithm Avatar asked Oct 24 '25 14:10

9Algorithm


1 Answers

You don't have to have /home/vagrant on your machine, it's the folder inside vagrant box (Homestead). Run vagrant ssh (password is vagrant) command to connect to the VM and you'll find /home/vagrant directory there.

like image 86
Alexey Mezenin Avatar answered Oct 26 '25 05:10

Alexey Mezenin



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!