feat: implement OIDC authentication and enhance user management features

- Introduced OIDC authentication support with new OIDCService, controller, and routes for handling OIDC login and callback processes.
- Updated user management functionalities to integrate OIDC, allowing users to authenticate via external providers.
- Enhanced localization files to include new strings related to OIDC authentication across multiple languages.
- Refactored existing components and hooks to support the new authentication flow, improving user experience during login and registration processes.
- Added new UI components for handling OIDC login and callback, ensuring a seamless integration with the existing application structure.
This commit is contained in:
Daniel Luiz Alves
2025-06-03 16:15:22 -03:00
parent 459783b152
commit 998b690659
93 changed files with 3328 additions and 454 deletions

View File

@@ -122,6 +122,61 @@ const defaultConfigs = [
value: "3600",
type: "number",
group: "security",
},
// OIDC SSO Configurations
{
key: "oidcEnabled",
value: "false",
type: "boolean",
group: "oidc",
},
{
key: "oidcIssuerUrl",
value: "",
type: "string",
group: "oidc",
},
{
key: "oidcClientId",
value: "",
type: "string",
group: "oidc",
},
{
key: "oidcClientSecret",
value: "",
type: "string",
group: "oidc",
},
{
key: "oidcRedirectUri",
value: "",
type: "string",
group: "oidc",
},
{
key: "oidcScope",
value: "openid profile email",
type: "string",
group: "oidc",
},
{
key: "oidcAutoRegister",
value: "true",
type: "boolean",
group: "oidc",
},
{
key: "oidcAdminEmailDomains",
value: "",
type: "string",
group: "oidc",
},
{
key: "serverUrl",
value: "http://localhost:3333",
type: "string",
group: "general",
}
];
@@ -133,7 +188,6 @@ async function main() {
let skippedCount = 0;
for (const config of defaultConfigs) {
// Check if configuration already exists
const existingConfig = await prisma.appConfig.findUnique({
where: { key: config.key },
});
@@ -144,7 +198,6 @@ async function main() {
continue;
}
// Only create if it doesn't exist
await prisma.appConfig.create({
data: config,
});