Start and run deployd.com API server while your Grunt task is running.
This plugin requires Grunt
npm install grunt-deployd --save-dev
The "deployd" task
- Your deployd server will start on the port that you specify in
- You have to specify
options.db.namefor your database, otherwise Grunt won't know what database should be used.
You have to add deployd:dev or deployd:prod to your task runner
Accessing API Endpoints
By default, this package will run your API endpoint on the port that you specified in
options.port. This is not very pretty when your app runs on a different port. You end up having you app on port 9000 ( or 80 ) and your API endpoints on port 7777.
To make your API endpoints accessible on the same port, you can use an HTTP Proxy. I included an example of how to use grunt-connect-proxy to proxy your API to /api directory on same port as the connect server.
Look in Gruntfile.js for an example of running a deployd server with a proxy
- This package includes Gruntfile.js that allows you to run tests of this package
Installation of tests
To install the tests, run
# npm install
Running in browser
To run tests in the browser, run
# grunt test:dev
To run headless tests, run
In lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using Grunt.