feat: Add internal runtime configuration
This commit is contained in:
@@ -61,7 +61,7 @@ module.exports.custom = {
|
||||
|
||||
internalAccessToken: process.env.INTERNAL_ACCESS_TOKEN,
|
||||
storageLimit: envToBytes(process.env.STORAGE_LIMIT),
|
||||
activeUserLimit: envToNumber(process.env.ACTIVE_USER_LIMIT),
|
||||
activeUsersLimit: envToNumber(process.env.ACTIVE_USERS_LIMIT),
|
||||
customerPanelUrl: process.env.CUSTOMER_PANEL_URL,
|
||||
demoMode: process.env.DEMO_MODE === 'true',
|
||||
|
||||
|
||||
@@ -42,6 +42,8 @@ module.exports.policies = {
|
||||
|
||||
'projects/create': ['is-authenticated', 'is-external', 'is-admin-or-project-owner'],
|
||||
|
||||
'_internal/update-config': ['is-authenticated', 'is-internal'],
|
||||
|
||||
'bootstrap/show': true,
|
||||
'terms/show': true,
|
||||
'access-tokens/create': true,
|
||||
|
||||
@@ -195,6 +195,8 @@ module.exports.routes = {
|
||||
'POST /api/notification-services/:id/test': 'notification-services/test',
|
||||
'DELETE /api/notification-services/:id': 'notification-services/delete',
|
||||
|
||||
'PATCH /api/_internal/config': '_internal/update-config',
|
||||
|
||||
'GET /preloaded-favicons/*': {
|
||||
fn: staticDirServer('/preloaded-favicons', () =>
|
||||
path.join(
|
||||
|
||||
Reference in New Issue
Block a user