Added postgres gem. Moved the db config to a template