|
|
|
@ -27,6 +27,12 @@ RUN cp -R conf /usr/local/srs/conf && \
|
|
|
|
|
cp -R research/players /usr/local/srs/objs/nginx/html/ && \
|
|
|
|
|
cp -R 3rdparty/signaling/www/demos /usr/local/srs/objs/nginx/html/
|
|
|
|
|
|
|
|
|
|
# Copy the shared libraries for FFmpeg.
|
|
|
|
|
RUN mkdir -p /usr/local/shared && \
|
|
|
|
|
cp $(ldd /usr/local/bin/ffmpeg |grep libxml2 |awk '{print $3}') /usr/local/shared/ && \
|
|
|
|
|
cp $(ldd /usr/local/bin/ffmpeg |grep libicuuc |awk '{print $3}') /usr/local/shared/ && \
|
|
|
|
|
cp $(ldd /usr/local/bin/ffmpeg |grep libicudata |awk '{print $3}') /usr/local/shared/
|
|
|
|
|
|
|
|
|
|
############################################################
|
|
|
|
|
# dist
|
|
|
|
|
############################################################
|
|
|
|
@ -40,10 +46,17 @@ RUN echo "BUILDPLATFORM: $BUILDPLATFORM, TARGETPLATFORM: $TARGETPLATFORM"
|
|
|
|
|
EXPOSE 1935 1985 8080 8000/udp 10080/udp
|
|
|
|
|
|
|
|
|
|
# FFMPEG 4.1
|
|
|
|
|
COPY --from=build /usr/local/shared/* /lib/
|
|
|
|
|
COPY --from=build /usr/local/bin/ffmpeg /usr/local/srs/objs/ffmpeg/bin/ffmpeg
|
|
|
|
|
# SRS binary, config files and srs-console.
|
|
|
|
|
COPY --from=build /usr/local/srs /usr/local/srs
|
|
|
|
|
|
|
|
|
|
# Test the version of binaries.
|
|
|
|
|
RUN ldd /usr/local/srs/objs/ffmpeg/bin/ffmpeg && \
|
|
|
|
|
/usr/local/srs/objs/ffmpeg/bin/ffmpeg -version && \
|
|
|
|
|
ldd /usr/local/srs/objs/srs && \
|
|
|
|
|
/usr/local/srs/objs/srs -v
|
|
|
|
|
|
|
|
|
|
# Default workdir and command.
|
|
|
|
|
WORKDIR /usr/local/srs
|
|
|
|
|
CMD ["./objs/srs", "-c", "conf/docker.conf"]
|
|
|
|
|