A Node.js service built as a test task for http://iotblue.net/
You need to have Node.js and MongoDB installed.
Clone this repository
git clone https://github.com/ishendyweb/nodejs-test test-task
cd test-task
Install dependencies
npm install
Add sample products
node seed/product-seeder.js
Start NodeJS server at http://localhost:3000 (./bin/www)
npm start
To change database configurations:
- Two files:
- app.js:
mongoose.connect('mongodb://localhost:27017/shopping', {
useMongoClient: true,
/* other options */
});
- seed/product-seeder.js:
mongoose.connect('mongodb://localhost:27017/shopping', {
useMongoClient: true,
/* other options */
});