Skip to content
Snippets Groups Projects

Resolve "Add dynamic configuration files"

Closed Markus Grigull requested to merge 27-add-dynamic-configuration-files into develop
3 files
+ 5
58
Compare changes
  • Side-by-side
  • Inline
Files
3
config/index.js 0 → 100644
+ 30
0
/**
* File: index.js
* Author: Markus Grigull <mgrigull@eonerc.rwth-aachen.de>
* Date: 10.05.2018
*
* This file is part of VILLASweb-backend.
*
* VILLASweb-backend is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* VILLASweb-backend is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with VILLASweb-backend. If not, see <http://www.gnu.org/licenses/>.
******************************************************************************/
'use strict';
const _ = require('lodash');
const defaults = require('./default');
const config = require('./' + (process.env.NODE_ENV || 'development'));
// merge configuration file with defaults
module.exports = _.merge({}, defaults, config, { environment: process.env.NODE_ENV || 'development' });
Loading