- integrate mongoose for mongo operation
- integrate ioredis for cache
- integrate gulp for build
- integrate pm2 for deploy
- integrate git-rev for server version
- integrate eslint for lint by airbnb rule
- integrate jwt for token generate and validation
- integrate apidoc for doc generate
- integrate graphql and graphiql for graphql support
- integrate morgan for logging
- integrate passport for authentication
- support ES7 async await
- suport database migration
- support multiple env
- support health check
- support routing
- Git
- Node.js and npm Node ^6.2.0, npm ^3.8.9
- gulp (
npm install -g gulp-cli
) - MongoDB Mongo ^3.2.x - Keep a running daemon with
mongod
- Redis-Server - Keep a running daemon with
redis-server
-
Run
npm install
to install server dependencies. -
Run
mongod
in a separate shell to keep an instance of the MongoDB Daemon running -
Run
redis-server
in a seperate shell to keep an instance of the Redis Server running
- Run
gulp
ormake run
to start a node server and watch the source code
- Select babel-node as node interceptor
- Start debug server/index.js in ide
- Run
gulp build
to build ci package - Run
gulp prod
to build prod package
- import airbnb.xml to Editor => Code Style => JavaScript
- use
ALT + CMD + L
to format the code