Rayrun
← Back to Discord Forum

video playback not working in docker

I'm unable to get video playback working in Docker despite the script working fine when running locally. Does anyone have tips here?

Locally I'm running ARM64 Apple Silicon. In my Docker image, I'm building for AMD64 on Debian. I've installed Firefox and Chrome (tested both) and ensured I had installed ffmpeg dependency so I had relevant codecs for audio and video. What could I be missing?

This thread is trying to answer question "Why is video playback not working in Docker despite working fine locally and what could be missing?"

3 replies

Also more generally curious to understand which browsers do support video playback, in particular HLS where I need H264 codec

Ok, got more logs. This only happens on Debian docker container, but works when I run outside Docker:

[JavaScript Error: "InvalidStateError: An attempt was made to use an object that is not, or is no longer, usable" {file: "chrome://juggler/content/content/WorkerMain.js" line: 6}] [JavaScript Error: "Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://redacted. (Reason: CORS request did not succeed). Status code: (null)."] VIDEOJS: ERROR: (CODE:4 MEDIA_ERR_SRC_NOT_SUPPORTED) The media could not be loaded, either because the server or network failed or because the format is not supported. JSHandle@object

ok, that was a huge pain in the ass to figure out. I disabled HTTPS, ended up sticking with Chrome (not Chromium) and had to get:

https://github.com/videojs/http-streaming#cdn

Related Discord Threads

TwitterGitHubLinkedIn
AboutQuestionsDiscord ForumBrowser ExtensionTagsQA Jobs

Rayrun is a community for QA engineers. I am constantly looking for new ways to add value to people learning Playwright and other browser automation frameworks. If you have feedback, email [email protected].