aboutsummaryrefslogtreecommitdiffstats
path: root/apps/workers
diff options
context:
space:
mode:
authorerik-nilcoast <138068205+erik-nilcoast@users.noreply.github.com>2025-03-16 16:58:18 -0500
committerGitHub <noreply@github.com>2025-03-16 21:58:18 +0000
commitbffbd43672ca9c3366b0e94c20fadb26d86dfdb9 (patch)
tree7e33979062f0dc45f0397026b7ad795c15b49450 /apps/workers
parent6bbf4cb1b9c4477a2db49a8151f7b79537c95637 (diff)
downloadkarakeep-bffbd43672ca9c3366b0e94c20fadb26d86dfdb9.tar.zst
feat(workers): allows videoWorker to use ytdlp command line arguments specified in the config. Fixes #775 #792 (#1117)
Diffstat (limited to 'apps/workers')
-rw-r--r--apps/workers/videoWorker.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/workers/videoWorker.ts b/apps/workers/videoWorker.ts
index 32f16f97..23ead8f8 100644
--- a/apps/workers/videoWorker.ts
+++ b/apps/workers/videoWorker.ts
@@ -63,7 +63,6 @@ export class VideoWorker {
}
function prepareYtDlpArguments(url: string, assetPath: string) {
- // TODO allow custom commandline arguments?
const ytDlpArguments = [url];
if (serverConfig.crawler.maxVideoDownloadSize > 0) {
ytDlpArguments.push(
@@ -71,6 +70,8 @@ function prepareYtDlpArguments(url: string, assetPath: string) {
`best[filesize<${serverConfig.crawler.maxVideoDownloadSize}M]`,
);
}
+
+ ytDlpArguments.push(...serverConfig.crawler.ytDlpArguments);
ytDlpArguments.push("-o", assetPath);
ytDlpArguments.push("--no-playlist");
return ytDlpArguments;