Set up better development defaults

This commit is contained in:
Timothy Warren 2016-02-19 09:30:29 -05:00
parent a37aaf0576
commit 0c712f4927
3 changed files with 31 additions and 10 deletions

18
.env.example Normal file
View File

@ -0,0 +1,18 @@
################################################################################
# Environment Configuration
################################################################################
NODE_ENV=development
HOST=localhost
# Enable/disable protocols
HTTP=true
HTTPS=false
# Server ports
HTTP_PORT=3000
HTTPS_PORT=3443
# Certificate paths are relative to the server.js file
HTTPS_CONFIG_KEY=localhost.key
HTTPS_CONFIG_CERT=localhost.crt

View File

@ -16,12 +16,10 @@ const configPath = path.resolve(__dirname, '../config');
const defaultConfig = new Map([
['host', 'localhost'],
['http', false],
['http', true],
['http-port', 80],
['https', true],
['https', false],
['https-port', 443],
['https-config-cert', path.join(configSslPath, 'localhost.crt')],
['https-config-key', path.join(configSslPath, 'localhost.key')],
['node-env', 'development'],
]);

View File

@ -1,26 +1,31 @@
{
"author": "Timothy J. Warren",
"dependencies": {
"bluebird": "^3.1.1",
"axios": "^0.9.1",
"body-parser": "~1.13.2",
"cookie-parser": "~1.3.5",
"debug": "~2.2.0",
"dotenv": "^2.0.0",
"errors": "^0.3.0",
"eslint": "^1.10.3",
"express": "4.*",
"getargs": "0.0.8",
"glob": "^6.0.4",
"helmet": "^1.1.0",
"lodash": "^4.5.0",
"morgan": "~1.6.1",
"nconf": "^0.8.2",
"node-dev": "^2.7.1",
"nodemon": "^1.9.0",
"winston": "^2.1.1"
},
"description": "An Opinionated Take on express with use of ES6 features",
"devDependencies": {
"chai": "3.4.*",
"chai": "^3.4.1",
"chai-as-promised": "^5.2.0",
"eslint": "1.10.*",
"gulp": "3.9.*",
"gulp-apidoc": "0.2.*",
"gulp-documentation": "2.1.*",
"gulp-eslint": "1.1.*",
"gulp-eslint": "^2.0.0",
"gulp-istanbul": "^0.10.3",
"gulp-jscs": "3.0.*",
"gulp-mocha": "2.2.*",
@ -55,7 +60,7 @@
"url": "https://github.com/timw4mail/crispy-train.git"
},
"scripts": {
"start": "node-dev server.js",
"start": "nodemon server.js",
"gulp": "gulp default",
"test": "gulp test"
},