summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--lib/config.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/config.js b/lib/config.js
index 1e5838e8..4d2fbf74 100644
--- a/lib/config.js
+++ b/lib/config.js
@@ -9,7 +9,11 @@ var config = require(path.join(__dirname, '..', 'config.json'))[env];
var debug = process.env.DEBUG ? (process.env.DEBUG === 'true') : ((typeof config.debug === 'boolean') ? config.debug : (env === 'development'));
// Create function that reads docker secrets but fails fast in case of a non docker environment
-var handleDockerSecret = fs.existsSync('/run/secrets/') ? function(secret){return fs.existsSync('/run/secrets/' + secret) ? fs.readFileSync('/run/secrets/' + secret) : null;)} : function () {return null}
+var handleDockerSecret = fs.existsSync('/run/secrets/') ? function(secret) {
+ return fs.existsSync('/run/secrets/' + secret) ? fs.readFileSync('/run/secrets/' + secret) : null;
+} : function() {
+ return null
+};
// url
var domain = process.env.DOMAIN || process.env.HMD_DOMAIN || config.domain || '';