Last Updated: February 25, 2016
· fernandoperigolo

Starting with Vagrant, Node JS, Express, Mondo DB, Heroku

I want to share with you a project of mine. I maked this to learn and maybe it can help you.

You can see the full tutorial and demo here:

The tips

After do my little API, what i learned is:

  • Use Vagrant as possible. You win total control about your ambient without broke or slow your machine. If something go wrong, just destroy Vagrant VM and vagrant up again;

  • We need a lot of cli apps, pump your console. Install iTerm or Console2. Study then and extract the best;

  • Heroku is a great tool. I do not fight with server;

  • Git is the thing who make modern development works. You need to be very close of it;

  • Crossdomain sucks. To test your API, you need to enable cross domain, something like this:

// Enabling Cross Domain
app.all('*', function(req, res, next) {
  res.header('Access-Control-Allow-Origin', '*');
  res.header('Access-Control-Allow-Methods', 'PUT, GET, POST, DELETE, OPTIONS');
  res.header('Access-Control-Allow-Headers', 'Content-Type');
Say Thanks