Browse Source

add node-youtube-dl download host env var in auto-updater

Rigel Kent 3 years ago
parent
commit
44fb529740
1 changed files with 1 additions and 1 deletions
  1. 1 1
      server/helpers/youtube-dl.ts

+ 1 - 1
server/helpers/youtube-dl.ts

@@ -138,7 +138,7 @@ async function updateYoutubeDLBinary () {
   const binDirectory = join(root(), 'node_modules', 'youtube-dl', 'bin')
   const bin = join(binDirectory, 'youtube-dl')
   const detailsPath = join(binDirectory, 'details')
-  const url = 'https://yt-dl.org/downloads/latest/youtube-dl'
+  const url = process.env.YOUTUBE_DL_DOWNLOAD_HOST || 'https://yt-dl.org/downloads/latest/youtube-dl'
 
   await ensureDir(binDirectory)