aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/middlewares/validators
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-02-08 10:51:10 +0100
committerChocobozzz <chocobozzz@cpy.re>2021-02-08 15:38:45 +0100
commit9129b7694d577322327ee79e9b9aa64deee92765 (patch)
treeeb23b7a952048c3725f29109d38c36368976dec0 /server/middlewares/validators
parent81b46cbc3417c46263c210c61b51a84a457abaaa (diff)
downloadPeerTube-9129b7694d577322327ee79e9b9aa64deee92765.tar.gz
PeerTube-9129b7694d577322327ee79e9b9aa64deee92765.tar.zst
PeerTube-9129b7694d577322327ee79e9b9aa64deee92765.zip
Allow to specify transcoding and import jobs concurrency
Diffstat (limited to 'server/middlewares/validators')
-rw-r--r--server/middlewares/validators/config.ts2
1 files changed, 2 insertions, 0 deletions
diff --git a/server/middlewares/validators/config.ts b/server/middlewares/validators/config.ts
index 52c28799f..71098ff99 100644
--- a/server/middlewares/validators/config.ts
+++ b/server/middlewares/validators/config.ts
@@ -39,6 +39,7 @@ const customConfigUpdateValidator = [
39 body('transcoding.enabled').isBoolean().withMessage('Should have a valid transcoding enabled boolean'), 39 body('transcoding.enabled').isBoolean().withMessage('Should have a valid transcoding enabled boolean'),
40 body('transcoding.allowAdditionalExtensions').isBoolean().withMessage('Should have a valid additional extensions boolean'), 40 body('transcoding.allowAdditionalExtensions').isBoolean().withMessage('Should have a valid additional extensions boolean'),
41 body('transcoding.threads').isInt().withMessage('Should have a valid transcoding threads number'), 41 body('transcoding.threads').isInt().withMessage('Should have a valid transcoding threads number'),
42 body('transcoding.concurrency').isInt({ min: 1 }).withMessage('Should have a valid transcoding concurrency number'),
42 body('transcoding.resolutions.0p').isBoolean().withMessage('Should have a valid transcoding 0p resolution enabled boolean'), 43 body('transcoding.resolutions.0p').isBoolean().withMessage('Should have a valid transcoding 0p resolution enabled boolean'),
43 body('transcoding.resolutions.240p').isBoolean().withMessage('Should have a valid transcoding 240p resolution enabled boolean'), 44 body('transcoding.resolutions.240p').isBoolean().withMessage('Should have a valid transcoding 240p resolution enabled boolean'),
44 body('transcoding.resolutions.360p').isBoolean().withMessage('Should have a valid transcoding 360p resolution enabled boolean'), 45 body('transcoding.resolutions.360p').isBoolean().withMessage('Should have a valid transcoding 360p resolution enabled boolean'),
@@ -51,6 +52,7 @@ const customConfigUpdateValidator = [
51 body('transcoding.webtorrent.enabled').isBoolean().withMessage('Should have a valid webtorrent transcoding enabled boolean'), 52 body('transcoding.webtorrent.enabled').isBoolean().withMessage('Should have a valid webtorrent transcoding enabled boolean'),
52 body('transcoding.hls.enabled').isBoolean().withMessage('Should have a valid hls transcoding enabled boolean'), 53 body('transcoding.hls.enabled').isBoolean().withMessage('Should have a valid hls transcoding enabled boolean'),
53 54
55 body('import.videos.concurrency').isInt({ min: 0 }).withMessage('Should have a valid import concurrency number'),
54 body('import.videos.http.enabled').isBoolean().withMessage('Should have a valid import video http enabled boolean'), 56 body('import.videos.http.enabled').isBoolean().withMessage('Should have a valid import video http enabled boolean'),
55 body('import.videos.torrent.enabled').isBoolean().withMessage('Should have a valid import video torrent enabled boolean'), 57 body('import.videos.torrent.enabled').isBoolean().withMessage('Should have a valid import video torrent enabled boolean'),
56 58