Skip to content

Commit

Permalink
Release (#13)
Browse files Browse the repository at this point in the history
* Add helm charts

* Rename to identity portal

* Add portal components

* Fix ci

* Fix ci

* Update configs

* Update keycloak realm

* Revert realm to master

* Add service calls and cookies

* Clear request uri on service change

* Fix cookie delete
  • Loading branch information
daniel-pimenta-DME authored Oct 29, 2023
1 parent 50393fe commit 83fb5bd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/app/@core/configs/keycloak.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ export function initializeKeycloak(keycloak: KeycloakService) {
keycloak.isLoggedIn().then(loggedIn => {
if (!loggedIn) {
const expirationDate: Date = new Date(0);
document.cookie = `${environment.cookies.token.name}=; expires=${expirationDate.toUTCString()}; path=/`;
document.cookie = `${environment.cookies.token.name}=; expires=${expirationDate.toUTCString()}; path=/; domain=${environment.cookies.token.domain}; SameSite=Stric`;
} else {
const token: string = keycloak.getKeycloakInstance().token;
if (token && token !== '') {
document.cookie = `${environment.cookies.token.name}=${token}; path=/; domain=${environment.cookies.token.domain}; expires=Session; SameSite=Strict`;
document.cookie = `${environment.cookies.token.name}=${token}; expires=Session; path=/; domain=${environment.cookies.token.domain}; SameSite=Strict`;
}
}
})
Expand Down
2 changes: 1 addition & 1 deletion src/environments/environment.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export const environment = {
cookies: {
token: {
name: 'auth_user_id',
domain: '.develop.eoepca.org'
domain: 'localhost'
}
}
};

0 comments on commit 83fb5bd

Please sign in to comment.