Selaa lähdekoodia

Try trust proxy

ghorsington 3 vuotta sitten
vanhempi
commit
c3782522d6
1 muutettua tiedostoa jossa 1 lisäystä ja 2 poistoa
  1. 1 2
      web/src/server.ts

+ 1 - 2
web/src/server.ts

@@ -38,10 +38,8 @@ const createSapperServer = async (): Promise<Express> => {
     app.use(
         session({
             secret: key,
-            // secureProxy: !dev,
             name: "session",
             secure: !dev,
-            httpOnly: !dev,
             domain: ENV.WEB_DOMAIN,
         }),
         compression({ threshold: 0 }),
@@ -51,6 +49,7 @@ const createSapperServer = async (): Promise<Express> => {
             }),
         }),
     );
+    app.set("trust proxy", true);
 
     return app;
 };