defaults in app configuration
envcould default toprocess.env.NODE_ENVwhen not suppliedserver.hostcould default toenv.NODE_HOST || env.HOST || '0.0.0.0'when not suppliedserver.portcould default toenv.NODE_PORT || env.PORT || 8080when not suppliedlogandservercould be made optional like app is
Good point! Would accept a PR ;)
See https://github.com/ditojs/dito/pull/34
I was wondering about logging defaults: how about having some turned on in development and disabling by default in production?
Good idea regarding logging defaults. Which ones do you suggest should be on in development by default?
We could use the defaults used in dito-example... In production everything is turned off and in development we have:
log: {
requests: false,
routes: false,
schema: false,
relations: false,
sql: false
},
And how about the app.cors.credentials and admin.api.cors.credentials settings in index.local.js with the comment "Only required for Dito.js Admin development to work on different port:"? Might make sense to add these as a default also?