diff options
author | Sheogorath | 2017-10-14 18:02:41 +0200 |
---|---|---|
committer | GitHub | 2017-10-14 18:02:41 +0200 |
commit | 5ce8f40eac7fccfcfca175cf79ccfa86a84bc113 (patch) | |
tree | 8cb0f7934d918528baf6e0c138bffe54d8f8cad0 /lib/config/environment.js | |
parent | ec8936a9f17ac90edfffa190ec7c91a99871ce27 (diff) | |
parent | 6bdc90d6ffd60cf8fe0509eb9fb3b2d47f185c31 (diff) |
Merge pull request #585 from xxyy/feature/hsts-cfg
Make HSTS Behaviour Configurable (Fixes #584)
Diffstat (limited to 'lib/config/environment.js')
-rw-r--r-- | lib/config/environment.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/config/environment.js b/lib/config/environment.js index c108a6f9..40b7e09f 100644 --- a/lib/config/environment.js +++ b/lib/config/environment.js @@ -8,6 +8,12 @@ module.exports = { port: process.env.HMD_PORT, urladdport: toBooleanConfig(process.env.HMD_URL_ADDPORT), usessl: toBooleanConfig(process.env.HMD_USESSL), + hsts: { + enable: toBooleanConfig(process.env.HMD_HSTS_ENABLE), + maxAgeSeconds: process.env.HMD_HSTS_MAX_AGE, + includeSubdomains: toBooleanConfig(process.env.HMD_HSTS_INCLUDE_SUBDOMAINS), + preload: toBooleanConfig(process.env.HMD_HSTS_PRELOAD) + }, protocolusessl: toBooleanConfig(process.env.HMD_PROTOCOL_USESSL), alloworigin: process.env.HMD_ALLOW_ORIGIN ? process.env.HMD_ALLOW_ORIGIN.split(',') : undefined, usecdn: toBooleanConfig(process.env.HMD_USECDN), |