A LAMP stack provisioned by Puppet.
Download and install the following versions from:
Hint: Newer versions might work, but this setup is confirmed to be stable across all platforms.
The vagrant-cachier plugin caches common packages which reduces the provisioning time for similar VM instances. Run the following from your console to install it:
vagrant plugin install vagrant-cachier
Add the following DNS entry to the hosts
file of your local machine:
10.0.0.42 local.application-a.de
10.0.0.42 local.application-b.de
Clone this repository to a nice place on your machine via:
git clone https://github.com/stadtwerk/vagrant_puppet_lamp.git
Fire up your console at the location you cloned the repository to and create the lamp-server
machine with:
vagrant up
When Vagrant is ready you can access the applications at:
The configuration of the lamp-server
machine happens within the ./provisioning
directory. That directory is automatically synchronized from the host machine to the /home/vagrant/provisioning
directory on the guest machine. The machine is provisioned in two steps:
1. Bootstrap
The ./provisioning/bootsrap.bash
prepares the lamp-server
machine to be provisioned with Puppet. It is executed once on the initial machine start up. It can be called manually with:
sudo bash bootstrap.bash
2. Puppet
The ./provisioning/puppet_apply.bash
applies the lamp.pp
Puppet manifest. It is executed on every machine start up. It can be called manually with:
sudo bash puppet_apply.bash
All application development happens within the ./application
directory. That directory is automatically synchronized from the host machine to the /var/www/application
directory on the guest machine.
You can access MySQL at 10.0.0.42:3306
with the user name and password root
. A phpMyAdmin installation is available at:
- http://10.0.0.42/phpmyadmin/ (user name and password
root
)
There are three ways to stop the running lamp-server
machine:
- Suspend with
vagrant suspend
- Shutdown with
vagrant halt
- Delete the virtual machine with
vagrant destroy
This project is licensed under the Creative Commons - Attribution-NonCommercial-ShareAlike 4.0 International.