-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
106 lines (101 loc) · 2.26 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
FROM python:3.6.5-alpine
#####################################################################
#
# A Docker image for running Python and FFMPEG code
#
# Image based on Alpine Linux
#
# with
# - Python 3.6.5
# - FFMPEG 3.4.2
#
#####################################################################
LABEL maintainer="[email protected]"
ENV FFMPEG_VERSION=3.4.2
WORKDIR /tmp/ffmpeg
RUN apk add --update --no-cache \
musl \
coreutils \
build-base \
nasm \
ca-certificates \
curl \
tar \
openssl-dev \
zlib-dev \
yasm-dev \
lame-dev \
freetype-dev \
opus-dev \
rtmpdump-dev \
x264-dev \
x265-dev \
xvidcore-dev \
libass-dev \
libwebp-dev \
libvorbis-dev \
libogg-dev \
libtheora-dev \
libvpx-dev \
# build and install ffmpeg
&& curl -s http://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.gz | tar zxvf - -C . \
&& cd ffmpeg-${FFMPEG_VERSION} \
&& ./configure \
--disable-debug \
--enable-version3 \
--enable-small \
--enable-gpl \
--enable-nonfree \
--enable-postproc \
--enable-openssl \
--enable-avresample \
--enable-libfreetype \
--enable-libmp3lame \
--enable-libx264 \
--enable-libx265 \
--enable-libopus \
--enable-libass \
--enable-libwebp \
--enable-librtmp \
--enable-libtheora \
--enable-libvorbis \
--enable-libvpx \
--enable-libxvid \
&& make -j"$(nproc)" install \
&& cd .. \
&& rm -rf ffmpeg-${FFMPEG_VERSION} \
# cleanup
&& apk del --purge \
coreutils \
build-base \
nasm \
curl \
tar \
openssl-dev \
zlib-dev \
yasm-dev \
lame-dev \
freetype-dev \
opus-dev \
xvidcore-dev \
libass-dev \
libwebp-dev \
libvorbis-dev \
libogg-dev \
libtheora-dev \
libvpx-dev \
&& apk add --no-cache \
zlib \
lame \
freetype \
faac \
opus \
xvidcore \
libass \
libwebp \
libvorbis \
libogg \
libtheora \
libvpx \
&& rm -rf /var/cache/apk/* \
ENTRYPOINT ["ffmpeg"]