LAMP stack setup based on CentOS 6.3 with Vagrant / Puppet
For anyone wanting to try out Vagrant, here's some sample code to help you setup your own LAMP dev sandbox quickly. It runs on CentOS 6.3 and the internal setup is done with Puppet.
Do note that the first run might take a while. Depending on your speed, 10 minutes to download the base VM (CentOS 6.3) and 5 minutes to startup and provision the VM. But subsequent startup should be quite fast.
You can spin up new boxes very easily. Just put your PHP scripts in the
projects folder and add a new vhost. If you are lazy, just throw your PHP files into the
Download from https://www.virtualbox.org/wiki/Downloads. Remember to download the VirtualBox Extension Pack.
Download from http://downloads.vagrantup.com.
Clone this repo into a local folder
$ git clone firstname.lastname@example.org:jmather/vagrant-lamp-centos63.git phpdev $ git submodule init $ git submodule update
4. Start Vagrant `cd` into the checked out folder to start the VM: ```bash $ vagrant up
Update your host operating system's
/etc/hosts file with the following entry:
Now, you can reach the webroot with
To login into the VM type
$ vagrant ssh
To stop the VM:
$ vagrant suspend
To halt the VM:
$ vagrant halt
To destroy the VM:
$ vagrant destroy
The phpMyAdmin URL:
Note: The MySQL username is
root and the root password is blank. To change the default, edit
Based on the excellent work from Patrick Daether.