On a fresh install of Ubuntu 15.04, and after doing a
sudo apt-get update && sudo apt-get upgrade
Install VirtualBox and Vagrant:
sudo apt-get install virtualbox
sudo apt-get install vagrant
Install the homestead box:
vagrant box add laravel/homestead
(option 1, virtualbox)
Install git:
sudo apt-get install git
Get Homestead:
git clone https://github.com/laravel/homestead.git Homestead
Go into the Homestead directory and create the Homestead configuration file:
cd Homestead
bash init.sh
Go to this directory
cd ~/.homestead
Where you find the homestead.yaml configuration file.
Create a key
ssh-keygen -t rsa -C "you@homestead"
enter 3 times (keep default location)
Change the key location in the homestead.yaml file in the authorize section (/home/xxx/.ssh/id_rsa.pub) + the keys section (/home/xxx/.ssh/id_rsa)
Create Code folder in your home folder /home/xxx:
cd ~
mkdir Code
Go into the Homestead directory in your home folder:
cd ~/Homestead
Run
vagrant up
Change hosts so you can surf to your Homestead box:
sudo nano /etc/hosts
Add the line
192.168.10.10 homestead.app
Go into the vagrant box
vagrant ssh
cd into the Code directory
cd Code
And download laravel in the default folder:
composer create-project laravel/laravel Laravel --prefer-dist
Now you can surf to http://homestead.app and it should show you 'Laravel 5'.
No comments:
Post a Comment