]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/initializers/checker-after-init.ts
Bigger video thumbnails for feeds
[github/Chocobozzz/PeerTube.git] / server / initializers / checker-after-init.ts
index b49ab6bca790d1bbab034c95ee2a898838b9d14e..2b00e2047e9770c57f8c896b59df94f0d6fe035b 100644 (file)
@@ -116,6 +116,16 @@ function checkConfig () {
     if (CONFIG.TRANSCODING.WEBTORRENT.ENABLED === false && CONFIG.TRANSCODING.HLS.ENABLED === false) {
       return 'You need to enable at least WebTorrent transcoding or HLS transcoding.'
     }
+
+    if (CONFIG.TRANSCODING.CONCURRENCY <= 0) {
+      return 'Transcoding concurrency should be > 0'
+    }
+  }
+
+  if (CONFIG.IMPORT.VIDEOS.HTTP.ENABLED || CONFIG.IMPORT.VIDEOS.TORRENT.ENABLED) {
+    if (CONFIG.IMPORT.VIDEOS.CONCURRENCY <= 0) {
+      return 'Video import concurrency should be > 0'
+    }
   }
 
   // Broadcast message
@@ -135,6 +145,13 @@ function checkConfig () {
     }
   }
 
+  // Live
+  if (CONFIG.LIVE.ENABLED === true) {
+    if (CONFIG.LIVE.ALLOW_REPLAY === true && CONFIG.TRANSCODING.ENABLED === false) {
+      return 'Live allow replay cannot be enabled if transcoding is not enabled.'
+    }
+  }
+
   return null
 }