The future of the php development environment
- 2. About the Speaker
• Originally from Cape Town South Africa been living and
working in London for 6 years.
• Developing with PHP on the lamp stack since 2002.
• Currently work at Comic Relief on their scalable
fundraising platform.
• Follow me on twitter @jeremyquinton
- 3. Red Nose Day is back 15th March 2013 so look out
for it
http://www.rednoseday.com
- 8. How does a newbie install php?
http://www.php.net/manual/en/install.php
- 10. EcoSystem around the Lamp Stack has changed
drastically
Linux/Windows/Mac OSX
Apache
MySQL
PHP
PHP has over 150 extensions
Cassandra Varnish Memcache Redis
Nginx ZeroMQ CouchDB
RabbitMQ MongoDB
Gearman
This is not a exhaustive list
- 11. The concept of a production snowflake in many ways can be applied to our
development environments - http://martinfowler.com/bliki/SnowflakeServer.html
- 13. Spot the difference is similar to
Dev/Prod Parity Concept
“Keep development, staging, and production
as similar as possible”
- http://12factor.net/
- 14. Summary of Past and Present problems
Setting up the modern dev environment,
which has many moving, parts isn't straightforward
Uniqueness
Switching between projects with different
dependancies is difficult
Local dev environments differ significantly from
production
- 15. The Present: A solution to these problems
$ vagrant up
@mitchellh creator and maintainer of vagrant
http://www.vagrantup.com/
- 16. What is the Vagrant Idea/Concept?
“A tool to transparently manage all the complex parts of modern development
within a virtual environment without affecting the everyday workflow of the
developer too much.” - http:/.vagrantup.com
Provider -
Vagrant Provisioner
virtualisation
- 17. Basic Vagrant Workflow
How vagrant works
Once Configured one command to bring up your development environment.
$ vagrant up
To access the virtual machine via ssh
$ vagrant ssh
When you finished work for the day
$ vagrant halt
When you done with the dev environment
$ vagrant destroy [vn-name]
Provision the virtual environment
$ vagrant provision
- 18. Vagrant command line options
Open source project written in Ruby, a command line tool. Supported on most major
operating systems.
- 20. Three methods to create a box file
Three methods create a box file
Download a box file from http://www.vagrant.es
Using the instructions off http://vagrantup.com
VeeWee https://github.com/jedi4ever/veewee
- 25. Quick Recap
Provider -
virtualisation
Vagrantfile
Provisioner
- 26. Visualisation of a vagrant workflow
Windows Developer
VCS
Mac Osx Developer
VagrantFile
Linux Developer
Chef Solo
Scripts
1. vagrant add box box_name package.box
2. vagrant up
3. vagrant provision
Deployment
tool Staging Production
- 28. Multi VM Environments
Accurately modeling a separate web and database
server within the same development environment.
Modeling a cluster of machines, and how they behave
together.
Testing a load balancer configuration, or the effects of
“unplugging” a machine.
- 37. Technical resources
• http://www.vagrantup.com
• http://www.virtualbox.org
• http://www.opscode.com/chef/
• https://github.com/jedi4ever/veewee
• https://github.com/mitchellh/vagrant