3 ms·
As long as your hardware can handle it, it's more than worth it. A few points: 1. I have a rule - never install server software on my base machine. Servers
by SkyMarshal 15y ago
As long as your hardware can handle it, it's more than worth it. A few points:
1. I have a rule - never install server software on my base machine. Servers and server frameworks (like Rails, Jetty, PostgreSQL, etc.) are only allowed on server OS's (Ubuntu Server) running in a virtual machine. That keeps a lot of cruft and extraneous processes out of my base install, while also quarantining them into easily clonable virtual machines, should I want to recreate the vm for something. I only break that rule with one thing - I run Nginx on my host OS, and just point it at different vm appservers.
2. It helps separate your work for multiple clients. So you could setup three vm's for client 1 and three for client 2 like so - client1-webserver.vdi, client1-appserver.vdi, client1-dbserver.vdi; client2-webserver.vdi, client2-appserver.vdi, client2-dbserver.vdi.
3. It lets you more accurately simulate the production environment of an n-tier application locally, so your dev environment will be closer to prod than if you ran all these server apps directly on your base machine.
Only caveat is you need the hardware to support this. Enough disk space for multiple ~10GB vm's, enough RAM to hold them in memory, and a CPU with VT-x (and VT-d if possible) and lots of cores. I particularly like Intel's Sandy Bridge chips for this, since every core is hyperthreaded, making it appear to the OS to have twice as many cores as it actually does. Each vm can be assigned one more more core.
That's about it. Try it with Virtual Box and see what you think.
- TwinEngine 15y agoHm. Interesting. So do you deploy your code to the VM? Or do you edit your work over an SSH connection and terminal editor?