Correction de l'URL de récupération du token dans la configuration de NextAuth pour inclure le royaume Keycloak.
This commit is contained in:
parent
cf6ea26879
commit
11d3fe70ed
@ -42,7 +42,7 @@ export const authOptions: NextAuthOptions = {
|
|||||||
// Rafraîchir le token si expiré
|
// Rafraîchir le token si expiré
|
||||||
try {
|
try {
|
||||||
const response = await fetch(
|
const response = await fetch(
|
||||||
`${process.env.KEYCLOAK_BASE_URL}/protocol/openid-connect/token`,
|
`${process.env.KEYCLOAK_BASE_URL}/realms/${process.env.KEYCLOAK_REALM}/protocol/openid-connect/token`,
|
||||||
{
|
{
|
||||||
method: "POST",
|
method: "POST",
|
||||||
headers: { "Content-Type": "application/x-www-form-urlencoded" },
|
headers: { "Content-Type": "application/x-www-form-urlencoded" },
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user