question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Chrome doesnt support mp4

See original GitHub issue

Current behavior:

Video (currently mp4) doesnt play in chrome

image

Desired behavior:

Video should play in Chrome

Versions

Latest


Please change or give option to record avi video… mp4 codecs has been dropped for chrome and it doesnt play the videos making it a hassle to download the file and open in in the video player software.

tried setting: "videoCompression": false, it didnt help

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
mikila85commented, Jul 25, 2019

Hi, If anyone ever encounters this,

We found that the browser had this error in Chrome-Devtools:

Refused to load media from ‘https://private-jenkins/lastSuccessfulBuild/artifact/cypress/videos/ovoc/3.site.spec.ts.mp4’ because it violates the following Content Security Policy directive: “default-src ‘none’”. Note that ‘media-src’ was not explicitly set, so ‘default-src’ is used as a fallback.

quick search in google will get you to: “Configuring Content Security Policy” which explains the problem and how to solve it

0reactions
onmomocommented, Jan 13, 2021

Hi, If anyone ever encounters this,

We found that the browser had this error in Chrome-Devtools:

Refused to load media from ‘https://private-jenkins/lastSuccessfulBuild/artifact/cypress/videos/ovoc/3.site.spec.ts.mp4’ because it violates the following Content Security Policy directive: “default-src ‘none’”. Note that ‘media-src’ was not explicitly set, so ‘default-src’ is used as a fallback.

quick search in google will get you to: “Configuring Content Security Policy” which explains the problem and how to solve it

You can either set the required CSP policy via Jenkins script console for testing until the next restart. (media-src 'self' ;)

System.setProperty("hudson.model.DirectoryBrowserSupport.CSP", "sandbox allow-same-origin; default-src 'none'; img-src 'self'; style-src 'self'; media-src 'self';")

Or permanently via JDK system properties

-Dhudson.model.DirectoryBrowserSupport.CSP="sandbox allow-same-origin; default-src 'none'; img-src 'self'; style-src 'self'; media-src 'self';"

To allow loading media files from the same jenkins domain.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Your Browser Does Not Support MP4 Videos: 3 Ways to Fix It
Chrome does not support any MP4 videos encoded with the h264 codec. If Firefox is showing MP4 videos not supported, it is either...
Read more >
html - .mp4 file not playing in chrome - Stack Overflow
On chrome, it does not play ,mp4 video. On firefox, it does. This is my HTML code: <video width="320" height="240" controls="controls"> ...
Read more >
How to Fix Embedded Videos Not Playing in Google Chrome
The first thing to try is disabling hardware acceleration in Chrome's Advanced Settings to fix the problem. You can get to Settings from...
Read more >
Fix videos & games that won't play - Google Chrome Help
Fix videos & games that won't play · Step 1: Turn on JavaScript · Step 2: Check your extensions, plugins, cache & cookies...
Read more >
Why and How to Fix Google Chrome Not Playing Videos?
Why and How to Fix Google Chrome Not Playing Videos? · 1. Update Chrome. · 2. Clear your cookies and cache. · 3....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found