The core service works, now – you can request a file by name, and you will be properly redirected to the S3 download location! The code is mostly clean, and things are looking pretty good. But, there seems to be a lot of hard coded configuration in the models and routes – something that shouldn’t […]
Having built a set of MongooseJS models and schemas, it would be nice to use them in a web application, right? Of course it would! But before we dive in deep with using our models to load and display data, there’s a pressing matter of routes and route organization in ExpressJS applications.
So you’ve been working on your Mongoose based app for a bit, and now you need to deploy it to a server somewhere – a testing environment, or even the production environment. Great! … But what do you do about the configuration string for your Mongoose code?