diff --git a/src/userService.ts b/src/userService.ts index 27c9cefd..2183e4d9 100644 --- a/src/userService.ts +++ b/src/userService.ts @@ -6,12 +6,14 @@ const _kc = new Keycloak({ clientId: import.meta.env.VITE_KC_CLIENT_ID, }); +const basePath = import.meta.env.VITE_URL_BASE_PATH ?? '' + export const initKeycloak = (renderAppCallback = () => {}) => { _kc .init({ onLoad: 'check-sso', silentCheckSsoRedirectUri: - window.location.origin + '/silent-check-sso.html', + `${window.location.origin}${basePath}/silent-check-sso.html`, pkceMethod: 'S256', adapter: 'default', })