By Casey Liss
It's That Easy?

A couple days ago, I wanted to see if I could deploy this site to a hosted platform. I knew that both Heroku and Azure had great support for Node.js, which is the platform this site is built on. I chose to try Heroku first, because in looking at both Heroku’s and Azure’s pricing, it was easier for me to understand that deploying to Heroku would be free in my use case.

At this point, I already had my project built and running locally, and also had a local git repository. I already had a standard node package.json. In every way, I felt ready. Thus, I took a look at Heroku’s quick-start documentation for Node, and started walking through it.

As I worked through the guide, I downloaded the Heroku toolbelt (command-line app), and after that, I was able to breeze through the guide, since I already had everything required of me. The first real action I had to take was to add a Procfile. My Procfile is one line; this is it:

web: node camel.js

(Note that camel.js is the entry point for my app.)

After installing the toolbelt, and creating the Procfile, I performed the following operations:

  1. heroku login to log into Heroku.
  2. heroku create to create the application within Heroku.
  3. git push heroku master to push my git repository to Heroku.
  4. heroku ps:scale web=1 to tell Heroku to create a dyno (a worker, to respond to web requests).
  5. heroku open to open Safari at my new, custom URL.

That was it. The only other thing I chose to do was to point my domain to Heroku:

heroku domains:add www.caseyliss.com

I was — and remain — stunned. I probably shouldn’t be, as Heroku has been around for a while now, but as someone who is used to working on the Microsoft ASP.NET stack, it was foreign. I’m used to standing up a server, fiddling with IIS settings, cursing some weirdo one-off issue that I’ve never seen before, and generally hating life until I get that first deployment done. While I expected things to be easier in this whole new world, I couldn’t imagine the only “real” task I had was to add a one-line file.

Not long ago we had the roll-a-raw-VM versus roll-using-high-level-tools debate. I’m working at a different level—a personal blog—and as such my priorities and needs are not the same as Marco’s and Justin’s. However, down here things are far less stressed and far less stressful. For something smaller and less demanding, it’s hard for me to reason through why you wouldn’t choose a solution like Heroku.