mirror of
https://github.com/fosrl/pangolin.git
synced 2025-07-02 18:14:56 +02:00
optionally generate traefik files, set cors in config, and set trust proxy in config
This commit is contained in:
parent
cb87463a69
commit
1aec431c36
13 changed files with 300 additions and 49 deletions
|
@ -20,7 +20,9 @@ const externalPort = config.getRawConfig().server.external_port;
|
|||
export function createApiServer() {
|
||||
const apiServer = express();
|
||||
|
||||
apiServer.set("trust proxy", 1);
|
||||
if (config.getRawConfig().server.trust_proxy) {
|
||||
apiServer.set("trust proxy", 1);
|
||||
}
|
||||
|
||||
const corsConfig = config.getRawConfig().server.cors;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue