Live data from Hacker News

Faster Web Development With Virtual Machines at deviantART

dt.deviantart.com

21–30 of 46 posts

Re: Faster Web Development With Virtual Machines at deviantART

#21
post #3

I do acknowledge that this is something that looks very "oh, how obvious!" to the modern crowd, but deviantART is a 10 year old PHP app... Of course, even if you're running a modern web framework in Ruby/Python/somethingtrendy, a VM makes a lot of sense. It lets you run the exact versions of everything that your production environment is, without having to worry about it.

Developing in the exact same environment as you deploy in should be standard practice.

Re: Faster Web Development With Virtual Machines at deviantART

#22
post #2

After talking with a few small PHP teams this seems like the logical conclusion whenever growing a team of PHP developers. Its just very hard to perfectly recreate your server environment locally on multiple OS's. Its a great solution, but I much prefer working with RoR or Python/Django where recreating the server environment locally is much easier.

How is creating the local server environment on RoR or Python/Django easier than PHP/anything? I've been developing locally for years and while I can't mimic the exact hardware of the live server, I wouldn't be able to do that regardless of stack I chose.

For the Python world, virtualenvs and pip requirement files make deploying a local copy of a project take about 30 seconds, and it's completely independent of your overall system and all other projects you happen to be working on.

Re: Faster Web Development With Virtual Machines at deviantART

#24
I've found that developing against a VM is a great tool for a dev. For OpenStack swift, we develop all of our code against a VM. Since we deploy on debian and I develop on a Mac, I can use OS X tools to develop (TextMate, etc) and code against an environment similar to our production. After code works on a VM, we can move to a lab or a staging environment to do more scale testing before deploying to production.

Developing against a VM is not something I did before working at Rackspace, and I find the practice so useful that I will do what I can to continue doing it no matter where I work in the future.

Re: Faster Web Development With Virtual Machines at deviantART

#25

Earlier quoted context omitted.

How is creating the local server environment on RoR or Python/Django easier than PHP/anything? I've been developing locally for years and while I can't mimic the exact hardware of the live server, I wouldn't be able to do that regardless of stack I chose.

For the Python world, virtualenvs and pip requirement files make deploying a local copy of a project take about 30 seconds, and it's completely independent of your overall system and all other projects you happen to be working on.

Gotcha. With git and a Phing build script, I can do the same in PHP :)

Re: Faster Web Development With Virtual Machines at deviantART

#26
post #2

After talking with a few small PHP teams this seems like the logical conclusion whenever growing a team of PHP developers. Its just very hard to perfectly recreate your server environment locally on multiple OS's. Its a great solution, but I much prefer working with RoR or Python/Django where recreating the server environment locally is much easier.

How is creating the local server environment on RoR or Python/Django easier than PHP/anything? I've been developing locally for years and while I can't mimic the exact hardware of the live server, I wouldn't be able to do that regardless of stack I chose.

As Pewpewarrows said, you can use pip with a virtualenv to deploy with one command. If your settings.py is any good, you can load your data dump in an sqlite database in one more command, and you're ready to go.

We used to develop historious like this, until we switched to redis/celery. Then it became too much hassle to install these in every machine, plus we wanted to test on the db we used (postgres) rather than sqlite, so we made a VM and now everything's dandy.

Re: Faster Web Development With Virtual Machines at deviantART

#27
post #10
post #8

Earlier quoted context omitted.

virtualenv

I'd say that seems to cover both bases for not needing a VM. Every language should have something as simple as these. Heck, it should be part of the OS, IMO; why I can't (easily) run two different versions of Firefox with two different profiles at the same time is beyond comprehension.

You do need a VM if you use memcached/redis/some other thing and don't want to install it on your machine. Other than that (for 90% of cases), virtualenv has you covered.

Re: Faster Web Development With Virtual Machines at deviantART

#28

I only skimmed the article but I assume it’s about the benefits of running VMs to have solid dev environments with zero setup cost. Let me ask another question: Will it become feasible to move code, tools and everything else into web services? Imagine you have your favorite editor (emacs, TM, vim) running in a browser window. Only that it’s live-updating like, e.g., Ethercodes or Wave. And you have very straight-forw…

I remember Heroku had something like this a few years ago. It was pretty easy to get a taste of Rails.

Re: Faster Web Development With Virtual Machines at deviantART

#30
post #10
post #8

Earlier quoted context omitted.

virtualenv

I'd say that seems to cover both bases for not needing a VM. Every language should have something as simple as these. Heck, it should be part of the OS, IMO; why I can't (easily) run two different versions of Firefox with two different profiles at the same time is beyond comprehension.

It's been a while since I've done this; but:

* Install your different Firefox versions in different locations (so one doesn't overwrite the other)

* Use "firefox -ProfileManager" to create at least one different 'profile', which is Firefox's user data set

* Use "firefox -P -no-remote" to launch Firefox. -no-remote allows multiple Firefox instances to run on the same machine. -P profilename is necessary because you need a separate profile for each running instance.

More info at http://kb.mozillazine.org/Command_line_arguments

Post reply on HN