GithubHelp home page GithubHelp logo

hubald / docker-ffmpeg-compiler Goto Github PK

View Code? Open in Web Editor NEW

This project forked from srwareham/docker-ffmpeg-compiler

0.0 0.0 0.0 32 KB

A docker container to compile ffmpeg and save a static linux binary to the host system

License: GNU General Public License v3.0

Shell 22.31% Dockerfile 77.69%

docker-ffmpeg-compiler's Introduction

Docker ffmpeg Compiler

Docker ffmpeg Compiler is a zero-set-up solution to install a fully featured ffmpeg binary on your linux system. All credit goes to the original author in https://github.com/srwareham/docker-ffmpeg-compiler (browse there for enhanced instructions), but this fork also adds HayVision libSRT support from the following fork: https://github.com/nebular/docker-build-ffmpeg-srt If you want to cut right to the chase and install ffmpeg and ffprobe, all at once, simply:

Running without cloning

This is the original installation method from the forked project. It conveniently creates the ffmpeg binaries in the calling directory.

bash -c "$(wget https://raw.githubusercontent.com/hubald/docker-ffmpeg-compiler/master/install.sh -O -)"

The above downloads and executes a script that:

  1. Downloads a Dockerfile
  2. Build a Docker image, which itself compiles all codecs and ffmpeg (warning, this takes a while)
  3. Copies static binaries for ffmpeg and ffprobe to a subfolder in the current working directory (with the uid / gid of the calling user)
  4. Deletes the ~1.2GB Docker image used to compile
  5. Leaves behind only the two static binaries mentioned above (each ~32MB)

Running by cloning

To further integrate this project in a bigger one, an alternate installation method is provided

git clone https://github.com/hubald/docker-build-ffmpeg-srt
cd docker-ffmpeg-compiler
./compile.sh

This method does not erase the docker image, and creates the output in $PWD/out/usr/local/bin.

Codecs and Features

Video

Audio

Other

Dependencies

  • Docker: installation instructions
  • The install script assumes you have set up docker to be run with non-root access. If you would rather not configure this, simply download the install.sh script and execute it as root (you'll then need to manually chown the binaries to that of your user account)

Why Use Docker ffmpeg Compiler?

ffmpeg and many of its constituent components use the GPL license. With only these features enabled, ffmpeg can be distributed in binary form. The problem becomes that many of its most desired codecs do not use a license that is compatible with the GPL, which means a "fully featured" ffmpeg cannot be distributed in binary form. If you have googled around to try to find such a binary distribution, you've almost certainly stumbled across the response: "build it yourself."

Docker ffmpeg Compiler steps in to do this for you! Rather than distribute a compiled version of ffmpeg, Docker Ffmpeg Compiler contains instructions to fetch and compile the source code for ffmpeg and the most popular codecs--no binaries distributed, all licenses respected.

Main Benefits

  1. Beginner friendly: With Docker Ffmpeg Compiler, no compilation experience is necessary, you simply run one script and you get the ffmpeg version you want!
  2. Ease of use: Even if you have experience compiling, finding the source for all the codecs, configuring their compilation with the right flags, and then compiling ffmpeg with all the right flags is a pain
  3. No clutter: The large number files downloaded and compiled for building ffmpeg are restricted to a docker namespace
  4. Significant size savings: The above files used to compile ffmpeg end up requiring ~1.2 GB. Using Docker Ffmpeg Compiler allows you to restore this space quickly and easily
  5. Portablity: You can run this code on any linux distribution with docker and it will work. If for some reason the static binary does not work on your system, you can always fire up another docker container to hold the binary and use it to do any encoding

Contributing

Contributions are welcome! If you would like to add a feature, improve this README, or improve existing code submit a pull request!

docker-ffmpeg-compiler's People

Contributors

hubald avatar jamshid avatar srwareham avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.