aboutsummaryrefslogtreecommitdiffhomepage
path: root/server.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server.ts')
-rw-r--r--server.ts6
1 files changed, 5 insertions, 1 deletions
diff --git a/server.ts b/server.ts
index 66dcb3c40..00cd87e20 100644
--- a/server.ts
+++ b/server.ts
@@ -103,7 +103,8 @@ import {
103 webfingerRouter, 103 webfingerRouter,
104 trackerRouter, 104 trackerRouter,
105 createWebsocketTrackerServer, 105 createWebsocketTrackerServer,
106 botsRouter 106 botsRouter,
107 downloadRouter
107} from './server/controllers' 108} from './server/controllers'
108import { advertiseDoNotTrack } from './server/middlewares/dnt' 109import { advertiseDoNotTrack } from './server/middlewares/dnt'
109import { Redis } from './server/lib/redis' 110import { Redis } from './server/lib/redis'
@@ -123,6 +124,7 @@ import { Hooks } from './server/lib/plugins/hooks'
123import { PluginManager } from './server/lib/plugins/plugin-manager' 124import { PluginManager } from './server/lib/plugins/plugin-manager'
124import { LiveManager } from './server/lib/live-manager' 125import { LiveManager } from './server/lib/live-manager'
125import { HttpStatusCode } from './shared/core-utils/miscs/http-error-codes' 126import { HttpStatusCode } from './shared/core-utils/miscs/http-error-codes'
127import { VideosTorrentCache } from '@server/lib/files-cache/videos-torrent-cache'
126 128
127// ----------- Command line ----------- 129// ----------- Command line -----------
128 130
@@ -202,6 +204,7 @@ app.use('/', botsRouter)
202 204
203// Static files 205// Static files
204app.use('/', staticRouter) 206app.use('/', staticRouter)
207app.use('/', downloadRouter)
205app.use('/', lazyStaticRouter) 208app.use('/', lazyStaticRouter)
206 209
207// Client files, last valid routes! 210// Client files, last valid routes!
@@ -258,6 +261,7 @@ async function startApplication () {
258 // Caches initializations 261 // Caches initializations
259 VideosPreviewCache.Instance.init(CONFIG.CACHE.PREVIEWS.SIZE, FILES_CACHE.PREVIEWS.MAX_AGE) 262 VideosPreviewCache.Instance.init(CONFIG.CACHE.PREVIEWS.SIZE, FILES_CACHE.PREVIEWS.MAX_AGE)
260 VideosCaptionCache.Instance.init(CONFIG.CACHE.VIDEO_CAPTIONS.SIZE, FILES_CACHE.VIDEO_CAPTIONS.MAX_AGE) 263 VideosCaptionCache.Instance.init(CONFIG.CACHE.VIDEO_CAPTIONS.SIZE, FILES_CACHE.VIDEO_CAPTIONS.MAX_AGE)
264 VideosTorrentCache.Instance.init(CONFIG.CACHE.TORRENTS.SIZE, FILES_CACHE.TORRENTS.MAX_AGE)
261 265
262 // Enable Schedulers 266 // Enable Schedulers
263 ActorFollowScheduler.Instance.enable() 267 ActorFollowScheduler.Instance.enable()