kinda working

This commit is contained in:
Micha Albert 2024-09-10 13:32:34 -04:00
parent e468e0b9ab
commit 35c2a98835
No known key found for this signature in database
GPG key ID: 33149159A417BBCE
6 changed files with 36 additions and 17 deletions

View file

@ -1,10 +1,16 @@
FROM alpine:3.20
FROM ubuntu:22.04
RUN apk add --no-cache gstreamer gstreamer-tools gst-plugins-bad
ARG DEBIAN_FRONTEND=noninteractive
RUN apk add --no-cache ffmpeg
RUN apt update
RUN apk add --no-cache bash libwpe libwpe-dev
RUN apt install -y ffmpeg
RUN apt install -y libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev libgstreamer-plugins-bad1.0-dev gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-wpe
RUN rm -rf /var/lib/apt/lists/*
RUN apt clean
COPY run.sh /

View file

@ -1,8 +1,14 @@
#!/bin/bash
gst-launch-1.0 -e wpesrc location="https://en.wikipedia.org/wiki/Main_Page" \
sleep 1
LIBGL_ALWAYS_SOFTWARE=true gst-launch-1.0 -e wpesrc location="http://web-frontend:4173/" \
! queue \
! videoconvert ! videoscale ! videorate \
! "video/x-raw, format=BGRA, width=854, height=480, framerate=30/1" \
! "video/x-raw, format=BGRA, width=1920, height=1080, framerate=30/1" \
! videoconvert \
! x264enc speed-preset=1 \
! filesink location=/dev/stdout | ffmpeg -re -y -i - -listen 1 -i rtmp://0.0.0.0:1936/active-input -c:v copy -c:a aac -map 0:v:0 -map 1:a:0 -t 10 -f flv rtmp://x.rtmp.youtube.com/live2/no-way-am-i-doing-that-again
! filesink location=/dev/stdout | ffmpeg -re -y -i - -listen 1 -i rtmp://0.0.0.0:1936/active-input -c:v copy -c:a libmp3lame -map 0:v:0 -map 1:a:0 -g 90 -framerate 30 -movflags faststart -bufsize 14000k -f flv rtmp://x.rtmp.youtube.com/live2/$YT_STREAM_KEY