Vagrant Dev-Environment Template, Reusable Local Provisioning
Overview
A reusable Vagrant template that stands up a consistent local LAMP-style development virtual machine, provisioned with Puppet and shell scripts. It served as the developer’s base box for spinning up project environments quickly and reproducibly during the early-career period.
Why It Exists
Before container-based workflows were standard, getting a uniform dev environment across machines was painful. This template solved that by codifying the VM, its networking, and its provisioning as version-controlled files, so any project could boot the same environment on demand.
What We Built
A Vagrantfile targeting an Ubuntu 12.04 (precise64) VirtualBox box with forwarded ports for HTTP (80) and LiveReload (35729), an NFS-less synced folder mapping the project into /var/www, a fixed VM name and tuned VirtualBox settings (memory, DNS host resolver, symlink support). Provisioning chained shell scripts (shell/update-puppet.sh, shell/librarian-puppet-vagrant.sh, an apt-update guard) into a Puppet run driven by a hiera.yaml data hierarchy and puppet/manifests. Supporting folders included files/, web/, and an xhprof/ directory for PHP profiling.
Technologies & Approach
Vagrant + VirtualBox for the VM, Puppet (with Hiera and Librarian-Puppet for module management) for configuration-as-code, and shell scripts for bootstrap steps. XHProf was included for performance profiling of PHP apps running inside the box. This mirrors the provisioning setup reused across sibling project folders of the era.
Outcome / Impact
Provided a dependable, repeatable local environment that eliminated “works on my machine” drift. As a template it was reused as the foundation for multiple other projects, proving its value as shared infrastructure tooling.
Capabilities Demonstrated
- Infrastructure-as-code for local development
- Automated VM provisioning with Puppet and Hiera
- Reproducible, port-forwarded LAMP-style environments
- Practical performance-profiling setup (XHProf) baked into the environment