A quick technical post this week. I've done away with Apache on my AWS server and am now using Node.js for all my web server needs.

The Problem

I'm constantly creating little web apps, for fun and to learn new concepts. I want to run them simultaneously and as separate apps. I've toyed around with Nodester and Nodejitsu (Heroku for Node.js) but wanted root access to the server. When I first started with Node.js I was using Apache on my free AWS server and setting up a new virtual host for each app. It worked alright but was a pain to quickly add new apps.

The Solution

I wrote a Node.js Server to listen in on port 80 and then proxy my apps running on various other ports. I started fresh on a new EC2 instance and didn't bother to install Apache.

The server was just a few lines of code and now I can add new apps with one line of code and restarting the Node.js app; much easier than what I was doing with Apache.

You can check out the server code on GitHub

I highly recommend trying this out if you're in a similar situation; feel free to reach out if you have any questions.