forked from alexellis/raspberrypi-youtube-streaming
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.template
34 lines (25 loc) · 856 Bytes
/
Dockerfile.template
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
# Build container
FROM resin/%%RESIN_MACHINE_NAME%%-debian:stretch AS build
WORKDIR /usr/src/app
RUN apt-get update \
&& apt-get -q install \
build-essential \
git \
libomxil-bellagio-dev \
pkg-config
RUN git clone --depth=1 https://github.com/FFmpeg/FFmpeg.git \
&& cd FFmpeg \
&& ./configure --arch=armhf --target-os=linux --enable-gpl --enable-omx --enable-omx-rpi --enable-nonfree --prefix="/opt/ffmpeg" \
&& make \
&& make install
# Runtime container
FROM resin/%%RESIN_MACHINE_NAME%%-debian:stretch
WORKDIR /usr/src/app
COPY --from=build /opt/ffmpeg/ /opt/ffmpeg/
ENV PATH="/opt/ffmpeg/bin:${PATH}"
RUN apt-get update \
&& apt-get -q install \
libraspberrypi-bin \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
COPY start.sh ./
CMD ["bash", "start.sh"]