Update CONTRIBUTING.md

Added a mention of INSECURE_USE_HTTP for development
This commit is contained in:
Sulka Haro
2019-07-30 13:43:55 +03:00
committed by GitHub
parent c2c534acf9
commit 65fbaa18a3
+2
View File
@@ -61,6 +61,8 @@ You can get the dev branch checked out using `git checkout dev`.
Once checked out, install the dependencies using `npm install`, then copy the included `my.env.template`file to `my.env` and edit the file to include your settings (like the Mongo URL). Leave the `NODE_ENV=development` line intact. Once set, run the site using `npm run dev`. This will start Nigthscout in the development mode, with different code packaging rules and automatic restarting of the server using nodemon, when you save changed files on disk. The client also hot-reloads new code in, but it's recommended to reload the the website after changes due to the way the plugin sandbox works.
Note the template sets `INSECURE_USE_HTTP` to `true` to enable the site to work over HTTP in local development.
If you want to additionaly test the site in production mode, create a file called `my.prod.env` that's a copy of the dev file but with `NODE_ENV=production` and start the site using `npm run prod`.
## REST API