X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fcontrollers%2Fapi%2Fconfig.ts;h=cfb750bc995e1f0d28632f53826e0b14a04b51c2;hb=98ebfa39500ce9dfbb782e43c4d269f9a2989698;hp=805ad99c7e0d48ddad6fec74f17ea0e440585cb3;hpb=8dd754c76735417305c4b68e2ada6f623e9d7650;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/controllers/api/config.ts b/server/controllers/api/config.ts index 805ad99c7..cfb750bc9 100644 --- a/server/controllers/api/config.ts +++ b/server/controllers/api/config.ts @@ -3,9 +3,7 @@ import { remove, writeJSON } from 'fs-extra' import { snakeCase } from 'lodash' import validator from 'validator' import { ServerConfigManager } from '@server/lib/server-config-manager' -import { UserRight } from '../../../shared' -import { About } from '../../../shared/models/server/about.model' -import { CustomConfig } from '../../../shared/models/server/custom-config.model' +import { About, CustomConfig, UserRight } from '@shared/models' import { auditLoggerFactory, CustomConfigAuditView, getAuditIdFromRes } from '../../helpers/audit-logger' import { objectConverter } from '../../helpers/core-utils' import { CONFIG, reloadConfig } from '../../initializers/config' @@ -169,6 +167,18 @@ function customConfig (): CustomConfig { whitelisted: CONFIG.SERVICES.TWITTER.WHITELISTED } }, + client: { + videos: { + miniature: { + preferAuthorDisplayName: CONFIG.CLIENT.VIDEOS.MINIATURE.PREFER_AUTHOR_DISPLAY_NAME + } + }, + menu: { + login: { + redirectOnSingleExternalAuth: CONFIG.CLIENT.MENU.LOGIN.REDIRECT_ON_SINGLE_EXTERNAL_AUTH + } + } + }, cache: { previews: { size: CONFIG.CACHE.PREVIEWS.SIZE @@ -227,6 +237,9 @@ function customConfig (): CustomConfig { live: { enabled: CONFIG.LIVE.ENABLED, allowReplay: CONFIG.LIVE.ALLOW_REPLAY, + latencySetting: { + enabled: CONFIG.LIVE.LATENCY_SETTING.ENABLED + }, maxDuration: CONFIG.LIVE.MAX_DURATION, maxInstanceLives: CONFIG.LIVE.MAX_INSTANCE_LIVES, maxUserLives: CONFIG.LIVE.MAX_USER_LIVES, @@ -246,6 +259,9 @@ function customConfig (): CustomConfig { } } }, + videoStudio: { + enabled: CONFIG.VIDEO_STUDIO.ENABLED + }, import: { videos: { concurrency: CONFIG.IMPORT.VIDEOS.CONCURRENCY,