The purpose of these Puppet scripts is to create a development environment for a single website or application. In the future, I hope to abstract these Puppet scripts into a more modular form. For now, they suit my own immediate needs.
- Clone this repository to your computer
- Specify your MySQL database settings in
provision/modules/mysql/manifests/params.pp
- Specify your nginx website domain in
provision/modules/nginx/manifests/params.pp
- Run
vagrant up
When your virtual machine is ready:
- Point your website domain to
192.168.33.10
in/etc/hosts
- Access your website on guest port
8080
- Access the xhprof UI on guest port
8081
- Access MySQL on host port
8306
- Listen for remote xdebug communication on host port
9000
Your website's public document root is the public/
directory.
- UNIX or Linux OS
- VirtualBox
- Vagrant
- Terminal/Console
I use the default precise64
base Vagrant box.
I use the defualt Ubuntu 12.04 LTS nginx
package.
I use the Ondřej Surý custom PPA to install PHP and related extensions. This allows me to use the latest PHP version while avoiding compiling PHP from source. This includes the following PHP extensions:
I include the xhprof extension and xhprof GUI. The GUI is available on guest port 8081
.
I include the xdebug extension. This extension will send remote debugging information to host port 9000
for integration with IDEs like PHPStorm.
- bcmath
- bz2
- calendar
- cgi-fcgi
- Core
- ctype
- curl
- date
- dba
- dom
- ereg
- exif
- fileinfo
- filter
- ftp
- gd
- gettext
- hash
- iconv
- intl
- json
- libxml
- mbstring
- mcrypt
- memcached
- mhash
- mysql
- mysqli
- mysqlnd
- openssl
- pcre
- PDO
- pdo_mysql
- pdo_sqlite
- Phar
- posix
- readline
- Reflection
- session
- shmop
- SimpleXML
- soap
- sockets
- SPL
- sqlite3
- standard
- sysvmsg
- sysvsem
- sysvshm
- tidy
- tokenizer
- wddx
- xdebug
- xhprof
- xml
- xmlreader
- xmlwriter
- Zend OPcache
- zip
- zlib
- Xdebug
- Zend OPcache
I use the defualt Ubuntu 12.04 LTS mysql-server
package. However, I also use a custom-tuned my.cnf
file generated by the Percona Configuration Wizard.
I use the defualt Ubuntu 12.04 LTS memcached
package.
- Fork this repository
- Create a new branch for each feature or improvement
- Send a pull request from your feature branch
It is very important to separate new features or improvements into separate feature branches, and to send a pull request for each branch. This allows us to review and pull in new features or improvements individually.
Copyright 2013, Josh Lockhart
MIT Public License