v1.15.0: TRUST_PROXY
This commit is contained in:
parent
1dd542bfdb
commit
b62ac06bd1
3 changed files with 4 additions and 2 deletions
|
@ -14,5 +14,6 @@ module.exports = {
|
||||||
shortTitle: process.env.SHORT_TITLE || 'Christmas',
|
shortTitle: process.env.SHORT_TITLE || 'Christmas',
|
||||||
useCDN: yesNo.parse(process.env.USE_CDN || true),
|
useCDN: yesNo.parse(process.env.USE_CDN || true),
|
||||||
wishlist: require('./wishlist'),
|
wishlist: require('./wishlist'),
|
||||||
base: (process.env.ROOT_PATH || '/').endsWith('/') ? (process.env.ROOT_PATH || '/') : `${process.env.ROOT_PATH}/`
|
base: (process.env.ROOT_PATH || '/').endsWith('/') ? (process.env.ROOT_PATH || '/') : `${process.env.ROOT_PATH}/`,
|
||||||
|
trustProxy: process.env.TRUST_PROXY === 'true' ? true : process.env.TRUST_PROXY || 'loopback'
|
||||||
};
|
};
|
||||||
|
|
1
index.js
1
index.js
|
@ -16,6 +16,7 @@ const logger = require('./logger');
|
||||||
|
|
||||||
const app = express();
|
const app = express();
|
||||||
app.set('base', config.base)
|
app.set('base', config.base)
|
||||||
|
app.set('trust proxy', config.trustProxy)
|
||||||
|
|
||||||
const db = new PouchDB(config.dbUrl);
|
const db = new PouchDB(config.dbUrl);
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
{
|
{
|
||||||
"name": "christmas-community",
|
"name": "christmas-community",
|
||||||
"version": "1.14.0",
|
"version": "1.15.0",
|
||||||
"description": "Christmas lists for communities",
|
"description": "Christmas lists for communities",
|
||||||
"main": "main.js",
|
"main": "main.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|
Loading…
Reference in a new issue