Browse Source

server: Added trustedProxy config.

1.0 1.0.5
Gisle Aune 6 years ago
parent
commit
7e94b0047c
  1. 1
      config.js
  2. 2
      package.json
  3. 5
      server.js

1
config.js

@ -5,6 +5,7 @@ const config = {
playgroundEndpoint: "http://127.0.0.1:17000/playground",
port: 8080,
root: "http://localhost:8080",
trustedProxy: null,
auth0: {
secret: "INVALID_SECRET",
clientId: "",

2
package.json

@ -1,6 +1,6 @@
{
"name": "@gisle/rpdata-frontend",
"version": "1.0.4",
"version": "1.0.5",
"description": "RPData (www.aiterp.net) frontend/proxy",
"main": "./index.js",
"scripts": {

5
server.js

@ -54,6 +54,11 @@ lasso.configure({
}
})
// Set trusted proxy
if (config.trustedProxy != null) {
app.set('trust proxy', config.trustedProxy)
}
// Apply middleware
app.use(markoExpress())
app.use(session)

Loading…
Cancel
Save