Boilerplate: ES6 Front End, Sass (with Bourbon and Neat), Gulp, Karma/Jasmine/Jasmine jQuery, Node.js, Express, express-vhost, MongoDB
by Jayson Jacobs
npm install -g gulp
npm install -g karma-cli
npm i
gem install neat
gem install sass
gem install bourbon
bourbon install
neat install
(you might need to use sudo for some of the above commands)
use forever or nodemon to run node.js.
installation:
npm install -g forever or
npm install -g nodemon
to run MongoDB:
mongod --config=db/mongo.conf
to run the server:
nodemon index.js will keep an open task (good for development) or
forever start index.js will spawn a daemon (good for production)
to stop the server:
ctrl+c if using nodemon or
forever stop index.js (use sudo if you used it to start forever)
run task gulp for development compilation.
run task karma start for testing.
default url: http://localhost:8001
Look in /index.js for vhost configuration.
make sure you have local virtual domains forwarded to 127.0.0.1 for development.
i.e.
127.0.0.1 virtualdomain.local
127.0.0.1 virtualdomainalt.local
in /etc/hosts
To run on a remote server, use the following task.
sudo NODE_ENV=prod forever start index.js
NODE_ENV=prod tells the application to run on port 80.