Merge pull request #1850 from atmire/use-x-forwarded-for-redirect

Use values from x-forwarded headers in getOrigin server side
This commit is contained in:
Tim Donohue
2022-09-28 10:31:16 -05:00
committed by GitHub
7 changed files with 36 additions and 14 deletions

View File

@@ -76,6 +76,10 @@ export function app() {
*/
const server = express();
// Tell Express to trust X-FORWARDED-* headers from proxies
// See https://expressjs.com/en/guide/behind-proxies.html
server.set('trust proxy', environment.ui.useProxies);
/*
* If production mode is enabled in the environment file:
* - Enable Angular's production mode