diff --git a/Dockerfile.client b/Dockerfile.client index 9e40e06e..e97a3151 100644 --- a/Dockerfile.client +++ b/Dockerfile.client @@ -15,26 +15,28 @@ RUN apt install -y --no-install-recommends cargo cargo-c WORKDIR /app -FROM builder AS builder-client - -COPY . . - -RUN cargo build --package=whipinto --release -RUN cargo build --package=whepfrom --release - -FROM builder AS builder-gstreamer - ADD https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/archive/gstreamer-1.22.8/gst-plugins-rs-gstreamer-1.22.8.tar.gz gst-plugins-rs-gstreamer.tar.gz RUN tar -xf gst-plugins-rs-gstreamer.tar.gz --strip-components 1 # whip / whep: protocol support -RUN cargo cinstall -p gst-plugin-webrtchttp --prefix=/usr --libdir=/usr/lib/$(gcc -dumpmachine) +RUN cargo cinstall -p gst-plugin-webrtchttp --libdir=pkg/usr/lib/$(gcc -dumpmachine) +# gst-plugin-webrtchttp +# - usr/lib/$(gcc -dumpmachine)/gstreamer-1.0/libgstwebrtchttp.a +# - usr/lib/$(gcc -dumpmachine)/gstreamer-1.0/libgstwebrtchttp.so +# - usr/lib/$(gcc -dumpmachine)/pkgconfig/gstwebrtchttp.pc +RUN rm pkg/usr/lib/$(gcc -dumpmachine)/gstreamer-1.0/libgstwebrtchttp.a # rtpav1pay / rtpav1depay: RTP (de)payloader for the AV1 video codec. -RUN cargo cinstall -p gst-plugin-rtp --prefix=/usr --libdir=/usr/lib/$(gcc -dumpmachine) +RUN cargo cinstall -p gst-plugin-rtp --libdir=pkg/usr/lib/$(gcc -dumpmachine) +# gst-plugin-rtp +# - usr/lib/$(gcc -dumpmachine)/gstreamer-1.0/libgstrsrtp.a +# - usr/lib/$(gcc -dumpmachine)/gstreamer-1.0/libgstrsrtp.so +# - usr/lib/$(gcc -dumpmachine)/pkgconfig/gstrsrtp.pc +RUN rm pkg/usr/lib/$(gcc -dumpmachine)/gstreamer-1.0/libgstrsrtp.a + +FROM common -COPY --from=builder-client /app/target/release/whipinto /usr/local/bin/whipinto -COPY --from=builder-client /app/target/release/whepfrom /usr/local/bin/whepfrom +COPY --from=builder /app/pkg/ / -CMD ["sh", "-c", "gst-launch-1.0 videotestsrc ! video/x-raw,width=640,height=480,format=I420 ! vp8enc ! rtpvp8pay ! whipsink whip-endpoint=http://localhost:3000/whip/777"] +CMD ["sh", "-c", "gst-launch-1.0 videotestsrc ! video/x-raw,width=640,height=480,format=I420 ! vp8enc ! rtpvp8pay ! whipsink whip-endpoint=http://localhost:7777/whip/777"] diff --git a/Dockerfile.server b/Dockerfile.server index ad7075f8..9b558b28 100644 --- a/Dockerfile.server +++ b/Dockerfile.server @@ -6,9 +6,15 @@ COPY . . RUN cargo build --release +RUN cargo build --package=whipinto --release +RUN cargo build --package=whepfrom --release + FROM debian:bookworm-slim COPY --from=builder /app/config-dist.toml /etc/live777/config.toml COPY --from=builder /app/target/release/live777 /usr/local/bin/live777 +COPY --from=builder /app/target/release/whipinto /usr/local/bin/whipinto +COPY --from=builder /app/target/release/whepfrom /usr/local/bin/whepfrom + CMD ["live777"]