1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-07-18 20:59:44 +02:00

ref: Refactoring

This commit is contained in:
Maksim Eltyshev 2023-10-19 16:05:34 +02:00
parent 9011ee61da
commit 0fab6075bd
23 changed files with 96 additions and 91 deletions

View file

@ -39,4 +39,9 @@ module.exports.custom = {
oidcScopes: process.env.OIDC_SCOPES || 'openid email profile',
oidcAdminRoles: process.env.OIDC_ADMIN_ROLES ? process.env.OIDC_ADMIN_ROLES.split(',') : [],
oidcRolesAttribute: process.env.OIDC_ROLES_ATTRIBUTE || 'groups',
// TODO: move client base url to environment variable?
oidcRedirectUri: `${
sails.config.environment === 'production' ? process.env.BASE_URL : 'http://localhost:3000'
}/oidc-callback`,
};

View file

@ -25,5 +25,5 @@ module.exports.policies = {
'show-config': true,
'access-tokens/create': true,
'access-tokens/exchange': true,
'access-tokens/exchange-using-oidc': true,
};

View file

@ -12,7 +12,7 @@ module.exports.routes = {
'GET /api/config': 'show-config',
'POST /api/access-tokens': 'access-tokens/create',
'POST /api/access-tokens/exchange': 'access-tokens/exchange',
'POST /api/access-tokens/exchange-using-oidc': 'access-tokens/exchange-using-oidc',
'DELETE /api/access-tokens/me': 'access-tokens/delete',
'GET /api/users': 'users/index',