-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmjpg_streamer.dockerfile
36 lines (30 loc) · 1.06 KB
/
mjpg_streamer.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
# syntax=docker/dockerfile:latest
FROM alpine:latest as build
LABEL maintainer="Valeriu Stinca <[email protected]>"
LABEL version="0.0.1-beta"
LABEL vendor="Strategic Zone"
LABEL release-date="2022-04-25"
RUN apk --no-cache add \
build-base \
cmake \
libjpeg-turbo-dev \
linux-headers \
openssl
# Install mjpg-streamer
RUN wget -qO- https://github.com/jacksonliam/mjpg-streamer/archive/master.tar.gz | tar xz
WORKDIR /mjpg-streamer-master/mjpg-streamer-experimental
RUN make && make install
# Build final image
FROM alpine:latest
LABEL maintainer="Valeriu Stinca <[email protected]>"
LABEL version="0.0.1-beta"
LABEL vendor="Strategic Zone"
LABEL release-date="2022-04-25"
RUN apk --no-cache add ffmpeg libjpeg openssh-client v4l-utils
COPY --from=build /usr/local/bin/mjpg_streamer /usr/local/bin
COPY --from=build /usr/local/lib/mjpg-streamer /usr/local/lib
COPY --from=build /usr/local/share/mjpg-streamer /usr/local/share
COPY ./mjpg_streamer.sh /usr/local/bin/mjpg_streamer.sh
RUN chmod +x /usr/local/bin/mjpg_streamer.sh
EXPOSE 36700
CMD ["/usr/local/bin/mjpg_streamer.sh"]