Implementar autenticación Authentik completa
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 25s
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 25s
- Backend: Nuevos endpoints /api/auth/status y /api/auth/check-group - Frontend: Composable useAuthentik para gestión de autenticación - Frontend: Componentes UserDropdown, UserAvatar, SessionStatusButton, GroupCheckButton - Frontend: Integración en topbar con dropdown de usuario - Config: URLs de Authentik y configuración de avatares - Lectura de headers x-authentik-* inyectados por Traefik - Verificación de grupos RBAC (frontend y backend) - Validación de sesión contra Authentik
This commit is contained in:
19
frontend/src/config/auth.js
Normal file
19
frontend/src/config/auth.js
Normal file
@@ -0,0 +1,19 @@
|
||||
/**
|
||||
* Configuración de autenticación Authentik
|
||||
*/
|
||||
|
||||
// URL base de Authentik (se puede configurar desde variable de entorno)
|
||||
export const AUTHENTIK_URL = import.meta.env.VITE_AUTHENTIK_URL || 'https://authentik.nucleoriofrio.com';
|
||||
|
||||
// Endpoints de Authentik
|
||||
export const AUTHENTIK_ENDPOINTS = {
|
||||
logout: `${AUTHENTIK_URL}/flows/-/default/invalidation/`,
|
||||
profile: `${AUTHENTIK_URL}/if/user/`,
|
||||
};
|
||||
|
||||
// Configuración de avatar
|
||||
export const AVATAR_CONFIG = {
|
||||
provider: 'https://ui-avatars.com/api/',
|
||||
defaultSize: 128,
|
||||
background: 'random',
|
||||
};
|
||||
Reference in New Issue
Block a user