From 366b8dcb056fee10c1d32e9311a8161047f1fe10 Mon Sep 17 00:00:00 2001 From: Daniel Lando Date: Thu, 25 Jan 2024 09:48:52 +0100 Subject: [PATCH] fix: auth check api not working with proxy Fixes #3553 --- docker/nginx/README.md | 2 ++ src/apis/ConfigApis.js | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/docker/nginx/README.md b/docker/nginx/README.md index a9f3c760f43..827dd1486ae 100644 --- a/docker/nginx/README.md +++ b/docker/nginx/README.md @@ -7,3 +7,5 @@ Test docker-compose file to try running zwave-js-ui behind a proxy with a custom ```bash docker-compose up -d ``` + +Then go to to access the UI. diff --git a/src/apis/ConfigApis.js b/src/apis/ConfigApis.js index ecade4e7750..10ee32ffb9e 100644 --- a/src/apis/ConfigApis.js +++ b/src/apis/ConfigApis.js @@ -59,7 +59,7 @@ export default { // const response = await request.get('/auth-enabled') // return response.data - const response = await fetch('/api/auth-enabled', { + const response = await fetch(axios.defaults.baseURL + '/auth-enabled', { credentials: 'include', redirect: 'manual', headers: {