Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ffmpeg/ffprobe #1815

Closed
amirmasoud opened this issue Sep 25, 2018 · 9 comments
Closed

ffmpeg/ffprobe #1815

amirmasoud opened this issue Sep 25, 2018 · 9 comments

Comments

@amirmasoud
Copy link

Info:

  • Docker version ($ docker --version): any
  • Laradock commit ($ git rev-parse HEAD): any
  • System info (Mac, PC, Linux): any
  • System info disto/version: any

does anyone have any suggestion to add ffmpeg to laradock? what is the best practice to do so?
so far I found this doc: http://sourcedigit.com/20614-install-ffmpeg-ubuntu-apt-get-install-ffmpeg-ubuntu-terminal/

is this requirement an specific one or I can make a PR?

@perezale
Copy link
Contributor

Hey, could you get this done? I'm trying to install it to the php-fpm container (as recommended for ffmpeg usage in general) but there a lot of guides using apk install or add-apt-repository which don't work with php-fpm base image.

Almost every install guide require external repository to be added. Any ideas on how to solve this situation?

@amirmasoud
Copy link
Author

I also installed it by adding the extra repo to the OS

@perezale
Copy link
Contributor

@amirmasoud Can you share your solution? Thanks in advance!

@amirmasoud
Copy link
Author

I didn't add it to Dockerfile, just installed them in the container (php-fpm),
I followed this tutorial: http://ubuntuhandbook.org/index.php/2018/10/install-ffmpeg-4-0-2-ubuntu-18-0416-04/ for installing FFmpeg

@AdrianHL
Copy link

AdrianHL commented Dec 20, 2018

I have added FFmpeg in the php-fpm container by adding the following lines to the Dockerfile (in my case Dockerfile-71):

#####################################
# FFmpeg:
#####################################

USER root

ARG INSTALL_FFMPEG=true
ENV INSTALL_FFMPEG ${INSTALL_FFMPEG}
RUN if [ ${INSTALL_FFMPEG} = true ]; then \
	echo 'deb http://ftp.uk.debian.org/debian jessie-backports main' >> /etc/apt/sources.list && \
	apt-get update && \
	apt-get install ffmpeg -y && \
	ffmpeg -version \
;fi

Please note that FFmpeg will be installed unless INSTALL_FFMPEG is set to false.

@ElioTohm
Copy link

ElioTohm commented May 7, 2019

i am a bit late but in case there is some1 reading this and the deb install did not work there is a simpler way
in workspace/Dockerfile the end of the file should look like this

#
#--------------------------------------------------------------------------
# Final Touch
#--------------------------------------------------------------------------
#

USER root

RUN apt-get clean && \
    rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* && \
    rm /var/log/lastlog /var/log/faillog

COPY --from=jrottenberg/ffmpeg:4.0-scratch / /

WORKDIR /var/www

as for the php-worker/Dockerfile the end of the file should look like this

#
#--------------------------------------------------------------------------
# Final Touch
#--------------------------------------------------------------------------
#

COPY --from=jrottenberg/ffmpeg:3.4-alpine / /

WORKDIR /etc/supervisor/conf.d/

this will leverage multi-staging in building the docker image plus jrottenberg/ffmpeg is very well maintained
hope this helps

@stale
Copy link

stale bot commented Feb 2, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the Stale label Feb 2, 2020
@stale
Copy link

stale bot commented Feb 23, 2020

Hi again 👋 we would like to inform you that this issue has been automatically closed 🔒 because it had not recent activity during the stale period. We really really appreciate your contributions, and looking forward for more in the future 🎈.

@stale stale bot closed this as completed Feb 23, 2020
@jayenne
Copy link

jayenne commented Mar 27, 2021

I have found Laradock installs ffmpeg 3 but need ffmpeg-4 and so edit the workspace/Dockerfile to replace

  ###########################################################################
  # FFMpeg:
  ###########################################################################
  if [ ${INSTALL_FFMPEG} = true ]; then \
    apt-get -yqq install ffmpeg; \
  fi

with

  ###########################################################################
  # FFMpeg:
  ###########################################################################
  if [ ${INSTALL_FFMPEG} = true ]; then \
    add-apt-repository ppa:jonathonf/ffmpeg-4 && \
    apt-get update && \
    apt-get install -yqq ffmpeg; \
  fi

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

No branches or pull requests

6 participants