Syntax for Heroku environment variables in config.yaml for node.js?

I've tried using:

db:
  uri: process.env.MONGOLAB_URI

but that doesn't seem to be working. (EDIT: in fact, that just returns the string of "process.env.MONGOLAB_URI") I've also tried:

<%= ENV['MONGOLAB_URI'] %>

but I saw that in article for an article about yaml in a ruby app (can't find the link now).

What's the correct syntax?

I believe the config.yaml example is for a specific Ruby driver. For Node.js you want to feed the URI (found at process.env.MONGOLAB_URI) into the Node driver of your choice using whatever configuration method you find most convenient.

If you wanted to use the Node MongoDB Native driver for example you might do something like this:

var mongodb = require('mongodb');
mongodb.Db.connect(process.env.MONGOLAB_URI, function (err, db) {
    // Do something cool with the db
});