Skip to content

Comments

Allow for specifying custom base url in install process#2

Merged
srubin merged 4 commits intoadd-ffprobefrom
sr/base-url-override
Feb 2, 2021
Merged

Allow for specifying custom base url in install process#2
srubin merged 4 commits intoadd-ffprobefrom
sr/base-url-override

Conversation

@srubin
Copy link

@srubin srubin commented Feb 2, 2021

Allows for setting FFMPEG_FFPROBE_STATIC_BASE_URL environment variable, and will fetch the ffmpeg/ffprobe binaries from that location.

Example:

FFMPEG_FFPROBE_STATIC_BASE_URL="https://www.google.com" yarn install
yarn install v1.17.3
[1/4] 🔍  Resolving packages...
[2/4] 🚚  Fetching packages...
[3/4] 🔗  Linking dependencies...
[4/4] 🔨  Building fresh packages...
error /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static: Command failed.
Exit code: 1
Command: node install.js
Arguments:
Directory: /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static
Output:
[ffmpeg-ffprobe-static] Using custom base url: https://www.google.com
Error: Download failed.
    at /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static/install.js:94:20
    at /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static/node_modules/@derhuerst/http-basic/lib/index.js:117:20
    at /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static/node_modules/@derhuerst/http-basic/lib/index.js:173:24
    at /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static/node_modules/@derhuerst/http-basic/lib/index.js:272:28
    at /Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static/node_modules/@derhuerst/http-basic/lib/index.js:302:17
    at ClientRequest.<anonymous> (/Users/srubin/code/test/node_modules/ffmpeg-ffprobe-static/node_modules/@derhuerst/http-basic/lib/index.js:337:13)
    at Object.onceWrapper (events.js:422:26)
    at ClientRequest.emit (events.js:315:20)
    at HTTPParser.parserOnIncomingClient [as onIncoming] (_http_client.js:641:27)
    at HTTPParser.parserOnHeadersComplete (_http_common.js:126:17) {
  url: 'https://www.google.com/b4.3.1-rc.5/ffmpeg-darwin-x64',
  statusCode: 404
}
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

@srubin srubin self-assigned this Feb 2, 2021
@srubin srubin requested a review from marcello3d February 2, 2021 17:19
@srubin srubin merged commit 86a3b73 into add-ffprobe Feb 2, 2021
@srubin srubin deleted the sr/base-url-override branch February 2, 2021 17:37
@srubin
Copy link
Author

srubin commented Dec 14, 2021

Goal of this is to be able to vendor builds of ffmpeg/ffprobe that we don't want to upload publicly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants