diff options
Diffstat (limited to 'server/initializers/constants.ts')
-rw-r--r-- | server/initializers/constants.ts | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts index 6f388420e..ab59320eb 100644 --- a/server/initializers/constants.ts +++ b/server/initializers/constants.ts | |||
@@ -24,7 +24,7 @@ import { CONFIG, registerConfigChangedHandler } from './config' | |||
24 | 24 | ||
25 | // --------------------------------------------------------------------------- | 25 | // --------------------------------------------------------------------------- |
26 | 26 | ||
27 | const LAST_MIGRATION_VERSION = 645 | 27 | const LAST_MIGRATION_VERSION = 650 |
28 | 28 | ||
29 | // --------------------------------------------------------------------------- | 29 | // --------------------------------------------------------------------------- |
30 | 30 | ||
@@ -77,6 +77,7 @@ const SORTABLE_COLUMNS = { | |||
77 | // Don't forget to update peertube-search-index with the same values | 77 | // Don't forget to update peertube-search-index with the same values |
78 | VIDEOS_SEARCH: [ 'name', 'duration', 'createdAt', 'publishedAt', 'originallyPublishedAt', 'views', 'likes', 'match' ], | 78 | VIDEOS_SEARCH: [ 'name', 'duration', 'createdAt', 'publishedAt', 'originallyPublishedAt', 'views', 'likes', 'match' ], |
79 | VIDEO_CHANNELS_SEARCH: [ 'match', 'displayName', 'createdAt' ], | 79 | VIDEO_CHANNELS_SEARCH: [ 'match', 'displayName', 'createdAt' ], |
80 | VIDEO_PLAYLISTS_SEARCH: [ 'match', 'displayName', 'createdAt' ], | ||
80 | 81 | ||
81 | ABUSES: [ 'id', 'createdAt', 'state' ], | 82 | ABUSES: [ 'id', 'createdAt', 'state' ], |
82 | 83 | ||
@@ -152,7 +153,7 @@ const JOB_ATTEMPTS: { [id in JobType]: number } = { | |||
152 | const JOB_CONCURRENCY: { [id in Exclude<JobType, 'video-transcoding' | 'video-import'>]: number } = { | 153 | const JOB_CONCURRENCY: { [id in Exclude<JobType, 'video-transcoding' | 'video-import'>]: number } = { |
153 | 'activitypub-http-broadcast': 1, | 154 | 'activitypub-http-broadcast': 1, |
154 | 'activitypub-http-unicast': 5, | 155 | 'activitypub-http-unicast': 5, |
155 | 'activitypub-http-fetcher': 1, | 156 | 'activitypub-http-fetcher': 3, |
156 | 'activitypub-cleaner': 1, | 157 | 'activitypub-cleaner': 1, |
157 | 'activitypub-follow': 1, | 158 | 'activitypub-follow': 1, |
158 | 'video-file-import': 1, | 159 | 'video-file-import': 1, |
@@ -245,7 +246,7 @@ const CONSTRAINTS_FIELDS = { | |||
245 | CAPTION_FILE: { | 246 | CAPTION_FILE: { |
246 | EXTNAME: [ '.vtt', '.srt' ], | 247 | EXTNAME: [ '.vtt', '.srt' ], |
247 | FILE_SIZE: { | 248 | FILE_SIZE: { |
248 | max: 2 * 1024 * 1024 // 2MB | 249 | max: 4 * 1024 * 1024 // 4MB |
249 | } | 250 | } |
250 | } | 251 | } |
251 | }, | 252 | }, |
@@ -274,7 +275,7 @@ const CONSTRAINTS_FIELDS = { | |||
274 | IMAGE: { | 275 | IMAGE: { |
275 | EXTNAME: [ '.png', '.jpg', '.jpeg', '.webp' ], | 276 | EXTNAME: [ '.png', '.jpg', '.jpeg', '.webp' ], |
276 | FILE_SIZE: { | 277 | FILE_SIZE: { |
277 | max: 2 * 1024 * 1024 // 2MB | 278 | max: 4 * 1024 * 1024 // 4MB |
278 | } | 279 | } |
279 | }, | 280 | }, |
280 | EXTNAME: [] as string[], | 281 | EXTNAME: [] as string[], |
@@ -296,7 +297,7 @@ const CONSTRAINTS_FIELDS = { | |||
296 | IMAGE: { | 297 | IMAGE: { |
297 | EXTNAME: [ '.jpg', '.jpeg' ], | 298 | EXTNAME: [ '.jpg', '.jpeg' ], |
298 | FILE_SIZE: { | 299 | FILE_SIZE: { |
299 | max: 2 * 1024 * 1024 // 2MB | 300 | max: 4 * 1024 * 1024 // 4MB |
300 | } | 301 | } |
301 | } | 302 | } |
302 | }, | 303 | }, |
@@ -307,7 +308,7 @@ const CONSTRAINTS_FIELDS = { | |||
307 | IMAGE: { | 308 | IMAGE: { |
308 | EXTNAME: [ '.png', '.jpeg', '.jpg', '.gif', '.webp' ], | 309 | EXTNAME: [ '.png', '.jpeg', '.jpg', '.gif', '.webp' ], |
309 | FILE_SIZE: { | 310 | FILE_SIZE: { |
310 | max: 2 * 1024 * 1024 // 2MB | 311 | max: 4 * 1024 * 1024 // 4MB |
311 | } | 312 | } |
312 | } | 313 | } |
313 | }, | 314 | }, |
@@ -447,9 +448,10 @@ const MIMETYPES = { | |||
447 | 'audio/ogg': '.ogg', | 448 | 'audio/ogg': '.ogg', |
448 | 'audio/x-ms-wma': '.wma', | 449 | 'audio/x-ms-wma': '.wma', |
449 | 'audio/wav': '.wav', | 450 | 'audio/wav': '.wav', |
451 | 'audio/x-wav': '.wav', | ||
450 | 'audio/x-flac': '.flac', | 452 | 'audio/x-flac': '.flac', |
451 | 'audio/flac': '.flac', | 453 | 'audio/flac': '.flac', |
452 | 'audio/aac': '.aac', | 454 | 'audio/aac': '.aac', |
453 | 'audio/m4a': '.m4a', | 455 | 'audio/m4a': '.m4a', |
454 | 'audio/mp4': '.m4a', | 456 | 'audio/mp4': '.m4a', |
455 | 'audio/x-m4a': '.m4a', | 457 | 'audio/x-m4a': '.m4a', |
@@ -702,7 +704,8 @@ const CUSTOM_HTML_TAG_COMMENTS = { | |||
702 | TITLE: '<!-- title tag -->', | 704 | TITLE: '<!-- title tag -->', |
703 | DESCRIPTION: '<!-- description tag -->', | 705 | DESCRIPTION: '<!-- description tag -->', |
704 | CUSTOM_CSS: '<!-- custom css tag -->', | 706 | CUSTOM_CSS: '<!-- custom css tag -->', |
705 | META_TAGS: '<!-- meta tags -->' | 707 | META_TAGS: '<!-- meta tags -->', |
708 | SERVER_CONFIG: '<!-- server config -->' | ||
706 | } | 709 | } |
707 | 710 | ||
708 | // --------------------------------------------------------------------------- | 711 | // --------------------------------------------------------------------------- |