mailer config path

This commit is contained in:
Joan Sanchez 2019-01-15 08:34:54 +01:00
parent f64569d070
commit 76bfd0db7a
2 changed files with 6 additions and 6 deletions

View File

@ -28,4 +28,4 @@ services:
environment:
- NODE_ENV
volumes:
- /config/vn-mailer:/config/vn-mailer
- /containers/vn-mailer:/etc/vn-mailer

View File

@ -1,8 +1,8 @@
require('require-yaml');
const fs = require('fs-extra');
const package = require('../package.json');
let configPath = `/config/${package.name}`;
let nginxConfigPath = '/config/nginx';
const packageJson = require('../package.json');
let configPath = `/etc/${packageJson.name}`;
let nginxConfigPath = configPath;
let env = process.env.NODE_ENV ? process.env.NODE_ENV : 'development';
@ -24,7 +24,7 @@ if (fs.existsSync(proxyEnvFile))
Object.assign(proxyConf, require(proxyEnvFile));
config.proxy = proxyConf;
config.package = package;
config.package = packageJson;
config.env = env;
module.exports = config;