Support the ongoing development of Laravel.io →
posted 8 years ago
Configuration
Last updated 2 years ago.
0

I use vagrant because I need PHP 7. I then have a ~/Homestead folder with the homestead.yaml file. I use the file to map my Code folder to the virtuel machine.

For each of my projects, I need to edit the homestead.yaml file and add the site like this:

sites:
  - map: larabook.app
    to: /home/vagrant/Code/laracast/public

 
  - map: larajobs.app
    to: /home/vagrant/Code/larajobs/public

For each site, I also update my hosts file.

In the Homestead folder:

vagrant up

Or:

vagrant up --provision
Last updated 8 years ago.
0

this is my homestead yaml file that runs 3 projects and each has their own local adress to be reached.

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

authorize: ~/.ssh/id_rsa.pub

keys:
    - ~/.ssh/id_rsa

folders:
    - map: /www/sites/Code
      to: /home/vagrant/Code

sites:
    - map: dev.dev
      to: /home/vagrant/Code/dev/public
    - map: jp-it.dev
      to: /home/vagrant/Code/jp-it/public
    - map: got.dev
      to: /home/vagrant/Code/got/public

databases:
    - dev
    - got
    - jpit

variables:
    - key: APP_ENV
      value: local

# blackfire:
#     - id: foo
#       token: bar
#       client-id: foo
#       client-token: bar

# ports:
#     - send: 93000
#       to: 9300
#     - send: 7777
#       to: 777
#       protocol: udp

same as ChristianGerdes i run vagrant up instead of homestead because of php7

0

dont forget to run command "vagrant provision" after you update the yaml file

0

Sign in to participate in this thread!

Eventy

Your banner here too?

ito2307 ito2307 Joined 24 Aug 2016

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2024 Laravel.io - All rights reserved.