PHP UK Conference 2013

El futuro de los entornos de desarrollo PHP

Jeremy Quinton  · 




Extracto de la transcripción automática del vídeo realizada por YouTube.

okay is this on can you guys hear me I can't pull it around a bit okay so just a bit about me like he said my name's Jeremy Quinton I'm a PHP developer of Indian PHP for about 10 years originally from Cape Town South Africa but I've been living

in London work in London for the past six years I currently work at comic relief on the scalable fundraising platform so just a bit of a shameless plug I thought I'd mention this because it's quite an interesting use case for PHP comic relief I've

got a massive implementation of PHP a lot of it bespoke but they use a lot of Drupal too and in 2011 they raised 108 million pounds for charity so PHP and you know indirectly is actually saving lives because most that money goes to some of the poorest communities

in Africa so it's quite a different use case red nose day is back on the fifteenth of March 2013 and so take a look out for it the night of TV's on BBC one that's really good ok so the feature of the PHP development environment I've broken

this talk up into three distinct posts parts so I basically talk about the past a bit so sort of the problems we've had with the PHP development environment I talked about the present so a present solution to solve some of these problems and then I talked

about the future and where that's going just a warning though the store contains Ruby I did a precursor to this talk at PHP London in December and I got a bit of stick because i was talking at a ph we meet up and you know two of the tools i talked today

about a ruby and to be honest I've never done Ruby commercially or anything like that i concurred in Ruby the only thing I can do is variable assignments and cut and paste which is what I've done but I think we've got to keep an open mind you know

we need to adopt and you know tools and techniques of other languages especially they're going to make our lives easier so let's talk a bit about the past so that literally there is my first development environment really cool monitor but that's

where I started out with PHP and in those days you know the paradigm was install everything locally and the stories for a lot of developers but generally you know the intern you're given a couple of toss and one of my first toss as an intern was you know

to set up my development environment and I remember it took me literally a couple of days you know you know learning how to use a package manager setting up a virtual host all those kind of things and you know that's that's where you start you know

you know the joke there's no place like localhost but but how does a newbie install PHP I mean those are the instructions of are literally just cut and paste this but you can see this sort of female you've got you know unix based system windows

and a bit there on Mac but you know there's quite a bit of stuff that especially if you're new to PHP and I think developers kind of got like sick of this we kind of got sick of this idea of having to install everything locally so we came up with some

solutions I've just got a couple year you guys might use something else but you know easy PHP zamp Sam's quite cool you get an extra feature you get Paul checked in for some reason you know then you might use a package manager Mac like homebrewer macports

you know something on Linux like app to Yammer and that's ma'am the gray ones man pro you actually can pay for a tool to set up your development environment which is quite interesting but we really try to you know sort of make our lives a bit easier

but the paradigm is still install everything like you know but the reality is the egos the ecosystem around the lamp stack has changed quite a bit so it's no longer just you know lamp we're using so many other technologies I mean that's not an

exhaustive list but you know using messaging we're using you know no sequel solution we're using something else in our PHP applications so all of a sudden you know installing everything locally and then installing a message queue locally on your computer

how does that work and you know you've got a dev on Mac and Anna Devon on windows how does the the windows developer you know does that messaging q even work on windows so the ecosystems changed so the modern developer environment has become more complex

for a lot of us but then there's also the concept of the snowflake and it's a really good blog post by Martin Fowler a lot of you'll know modern Farley's from its books but I definitely recommend you go and you know read it but the concept

of the production snowflakes in many ways can be applied to our development environments the general concept is of uniqueness the fact that you know a lot of our development environments are unique so for example if you took everyone in this room if you took

each of our development environments you'll probably find they're pretty unique in structure just like snowflakes are unique but one developer you know wants to get a change from his development environment to another developers machine that's

not straightforward and easy to do and also the idea that our development environments on reproducible so you know you've been developing and hacking away on PHP for two years locally you've made so many hacks and configurations and so on your hard

drive crashes you know it takes you two days to get back up and running to where you were and you can t remember how you did things you start googling and you know and so on and so forth then let's play a little game okay so spot the difference can anyone

spot the difference in these pictures is about seven anyone yeah so there we go so there's a there's a there's a couple of you know differences and spot the difference is is really it's really simple as a similar to the dev parity concept right

and the dev pod parity concept is keep development staging and production as similar as possible right a lot of the times that's not true out of development environments or completely different to staging and production 12 factor donate i really recommend

that site and there's 12 points in their bath you know deploying and doing stuff with your applications it was put up i think some of the guys who did the europa platform but their parity is one of the concepts there and their pod parody is broken up into

three things you know it's time so you know you're right code today but it only maybe goes live in a week and it's got a people element to it so basically the guys that are writing the code the guys deploying the code and then is the tools gap

you know so basically our development environment is comment you know to staging and production so it's a really important concept and the tools i'm going to talk about later you know solve this problem so let's go to a quick summary of these past

and present problems right so setting up the modern development environment we've got all these moving parts isn't straightforward see there's a bit of a mistake therefore the comments over this idea of uniqueness so like a snowflake our development

environment so unique in structure and switching being between projects with different dependencies is difficult so let's say you're working on two different api's you know one API is dependent on some back in service maybe MongoDB even another

AP API that's maybe that a message in queue behind it you know you said all that stuff up locally switching between those two projects and developing on both them you know the dependencies and stuff start to maybe you know conflict and and then you know

dev parity that our local development environments differ significantly from production and staging and so on so how do we solve these problems and you know these are some of the problems I've encountered maybe even kind of some of them and I'm sure

these there's other problems you guys have encountered but how do we solve them fragrance right I don't know how many people in this room are using vagrant at the moment okay that's really cool for those that aren't using it a dog you'd

is the future and because it's drastically changed the way we configure and set up our development environments and the idea is pretty simple this is a high-level concept on the slide but once you've configured vagrant its fragrant up there's you

know that's on the command line so you drop into a terminal whatever but vagrant up and it brings up your development environment so that's really cool so we take everyone in this room we distribute that we give everyone a copy of the development environment

everyone's very grown up and everyone's got the same development environment it's really really useful so just to put more about the variant idea and the concept so I took a definition of you know very gonna calm but it's a tool to transparently

manage all the complex parts of modern development within a virtual environment without affecting the everyday work love develop too much so I kind of like to think of vagrant as the magic but the idea is you that you've got a provider which is a virtualization

so over yeah I've got VirtualBox I don't know if any of you have used virtualbox it's a really really cool tool you know it's completely free it's a virtualization tool it's open source and it's back by Oracle this these days you

know frequent updates of it all the time which is really good but you've you've got very then you've got a provider for your virtualization so your development environment is virtualized and then you've got a provisioner so chef is the example

[ ... ]

Nota: se han omitido las otras 4.930 palabras de la transcripción completa para cumplir con las normas de «uso razonable» de YouTube.