diff options
Diffstat (limited to 'server/controllers')
-rw-r--r-- | server/controllers/activitypub/client.ts | 2 | ||||
-rw-r--r-- | server/controllers/static.ts | 13 |
2 files changed, 11 insertions, 4 deletions
diff --git a/server/controllers/activitypub/client.ts b/server/controllers/activitypub/client.ts index f616047b0..0d1dff96f 100644 --- a/server/controllers/activitypub/client.ts +++ b/server/controllers/activitypub/client.ts | |||
@@ -124,7 +124,7 @@ activityPubClientRouter.get('/redundancy/videos/:videoId/:resolution([0-9]+)(-:f | |||
124 | executeIfActivityPub(asyncMiddleware(videoFileRedundancyGetValidator)), | 124 | executeIfActivityPub(asyncMiddleware(videoFileRedundancyGetValidator)), |
125 | executeIfActivityPub(asyncMiddleware(videoRedundancyController)) | 125 | executeIfActivityPub(asyncMiddleware(videoRedundancyController)) |
126 | ) | 126 | ) |
127 | activityPubClientRouter.get('/redundancy/video-playlists/:streamingPlaylistType/:videoId', | 127 | activityPubClientRouter.get('/redundancy/streaming-playlists/:streamingPlaylistType/:videoId', |
128 | executeIfActivityPub(asyncMiddleware(videoPlaylistRedundancyGetValidator)), | 128 | executeIfActivityPub(asyncMiddleware(videoPlaylistRedundancyGetValidator)), |
129 | executeIfActivityPub(asyncMiddleware(videoRedundancyController)) | 129 | executeIfActivityPub(asyncMiddleware(videoRedundancyController)) |
130 | ) | 130 | ) |
diff --git a/server/controllers/static.ts b/server/controllers/static.ts index b21f9da00..639445b74 100644 --- a/server/controllers/static.ts +++ b/server/controllers/static.ts | |||
@@ -1,6 +1,13 @@ | |||
1 | import * as cors from 'cors' | 1 | import * as cors from 'cors' |
2 | import * as express from 'express' | 2 | import * as express from 'express' |
3 | import { CONFIG, HLS_PLAYLIST_DIRECTORY, ROUTE_CACHE_LIFETIME, STATIC_DOWNLOAD_PATHS, STATIC_MAX_AGE, STATIC_PATHS } from '../initializers' | 3 | import { |
4 | CONFIG, | ||
5 | HLS_STREAMING_PLAYLIST_DIRECTORY, | ||
6 | ROUTE_CACHE_LIFETIME, | ||
7 | STATIC_DOWNLOAD_PATHS, | ||
8 | STATIC_MAX_AGE, | ||
9 | STATIC_PATHS | ||
10 | } from '../initializers' | ||
4 | import { VideosPreviewCache } from '../lib/cache' | 11 | import { VideosPreviewCache } from '../lib/cache' |
5 | import { cacheRoute } from '../middlewares/cache' | 12 | import { cacheRoute } from '../middlewares/cache' |
6 | import { asyncMiddleware, videosGetValidator } from '../middlewares' | 13 | import { asyncMiddleware, videosGetValidator } from '../middlewares' |
@@ -53,9 +60,9 @@ staticRouter.use( | |||
53 | 60 | ||
54 | // HLS | 61 | // HLS |
55 | staticRouter.use( | 62 | staticRouter.use( |
56 | STATIC_PATHS.PLAYLISTS.HLS, | 63 | STATIC_PATHS.STREAMING_PLAYLISTS.HLS, |
57 | cors(), | 64 | cors(), |
58 | express.static(HLS_PLAYLIST_DIRECTORY, { fallthrough: false }) // 404 if the file does not exist | 65 | express.static(HLS_STREAMING_PLAYLIST_DIRECTORY, { fallthrough: false }) // 404 if the file does not exist |
59 | ) | 66 | ) |
60 | 67 | ||
61 | // Thumbnails path for express | 68 | // Thumbnails path for express |