feat: Add legal requirements (#1306)

This commit is contained in:
Maksim Eltyshev
2025-08-21 15:10:02 +02:00
committed by GitHub
parent bb40a22563
commit 2f4bcb0583
122 changed files with 1522 additions and 81 deletions
+1 -1
View File
@@ -35,7 +35,7 @@ module.exports.custom = {
baseUrlPath: parsedBasedUrl.pathname,
baseUrlSecure: parsedBasedUrl.protocol === 'https:',
tokenExpiresIn: parseInt(process.env.TOKEN_EXPIRES_IN, 10) || 365,
tokenExpiresIn: (parseInt(process.env.TOKEN_EXPIRES_IN, 10) || 365) * 24 * 60 * 60,
// Location to receive uploaded files in. Default (non-string value) is a Sails-specific location.
uploadsTempPath: null,
+3
View File
@@ -36,6 +36,9 @@ module.exports.policies = {
'projects/create': ['is-authenticated', 'is-external', 'is-admin-or-project-owner'],
'config/show': true,
'terms/show': true,
'access-tokens/create': true,
'access-tokens/exchange-with-oidc': true,
'access-tokens/accept-terms': true,
'access-tokens/revoke-pending-token': true,
};
+4
View File
@@ -64,6 +64,8 @@ function staticDirServer(prefix, dirFn) {
module.exports.routes = {
'GET /api/config': 'config/show',
'GET /api/terms/:type': 'terms/show',
'GET /api/webhooks': 'webhooks/index',
'POST /api/webhooks': 'webhooks/create',
'PATCH /api/webhooks/:id': 'webhooks/update',
@@ -71,6 +73,8 @@ module.exports.routes = {
'POST /api/access-tokens': 'access-tokens/create',
'POST /api/access-tokens/exchange-with-oidc': 'access-tokens/exchange-with-oidc',
'POST /api/access-tokens/accept-terms': 'access-tokens/accept-terms',
'POST /api/access-tokens/revoke-pending-token': 'access-tokens/revoke-pending-token',
'DELETE /api/access-tokens/me': 'access-tokens/delete',
'GET /api/users': 'users/index',