PHP Development in Linux or Mac OS X?

Posted by Kirby Turner on August 14, 2008

I’m planning to move a web site from ASP.NET to PHP. My primary development machine is a MacBook Pro. I use VMware Fusion for hosting a number of different OSes including Windows and Linux (mostly Ubuntu). So now I’m wondering what type of development environment I should setup for working with this new PHP based web site.

Should I develop directly within OS X? It’s definitely convenient. But I don’t need services such as Apache, Postgres, etc running on my laptop all the time. Also, I’m concerned that it might introduce my laptop to additional security risks.

Should I develop within a Linux guest OS? This is not as convenient as doing development within my host OS but it does mean my LAMP development environment is not running all the time wasting system resources when I’m not doing development work. And it is also more secure because I can restrict access to the guest OS.

So my latest thinking is to use a hybrid approach. I’ll setup a Ubuntu LAMP server as a guest OS using VMware Fusion. Then use a file share so I can edit the web site files within the host OS. It seems like this approach gives me the best of both worlds. I can edit files in OS X using an editor like TextMate while hosting and testing the web site on a LAMP server. Hmmm, I think maybe this is the right approach for me.


Posted in programming. Tagged in .