https://github.com/flavioribeiro/donut Skip to content Navigation Menu Toggle navigation Sign in * Product + Actions Automate any workflow + Packages Host and manage packages + Security Find and fix vulnerabilities + Codespaces Instant dev environments + GitHub Copilot Write better code with AI + Code review Manage code changes + Issues Plan and track work + Discussions Collaborate outside of code Explore + All features + Documentation + GitHub Skills + Blog * Solutions By size + Enterprise + Teams + Startups By industry + Healthcare + Financial services + Manufacturing By use case + CI/CD & Automation + DevOps + DevSecOps * Resources Topics + AI + DevOps + Security + Software Development Explore + Learning Pathways + White papers, Ebooks, Webinars + Customer Stories + Partners * Open Source + GitHub Sponsors Fund open source developers + The ReadME Project GitHub community articles Repositories + Topics + Trending + Collections * Enterprise + Enterprise platform AI-powered developer platform Available add-ons + Advanced Security Enterprise-grade security features + GitHub Copilot Enterprise-grade AI features + Premium Support Enterprise-grade 24/7 support * Pricing Search or jump to... Search code, repositories, users, issues, pull requests... Search [ ] Clear Search syntax tips Provide feedback We read every piece of feedback, and take your input very seriously. [ ] [ ] Include my email address so I can be contacted Cancel Submit feedback Saved searches Use saved searches to filter your results more quickly Name [ ] Query [ ] To see all available qualifiers, see our documentation. Cancel Create saved search Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }} flavioribeiro / donut Public * Notifications You must be signed in to change notification settings * Fork 7 * Star 197 donut is a zero setup required SRT+MPEG-TS -> WebRTC Bridge powered by Pion. License Apache-2.0 license 197 stars 7 forks Branches Tags Activity Star Notifications You must be signed in to change notification settings * Code * Issues 5 * Pull requests 0 * Actions * Projects 0 * Security * Insights Additional navigation options * Code * Issues * Pull requests * Actions * Projects * Security * Insights flavioribeiro/donut This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository. main BranchesTags Go to file Code Folders and files Name Name Last commit Last commit message date Latest commit History 165 Commits .github .github doc doc fonts/0xProto fonts/0xProto internal internal scripts scripts static static .dockerignore .dockerignore .gitattributes .gitattributes .gitignore .gitignore DOCKER_DEVELOPMENT.md DOCKER_DEVELOPMENT.md Dockerfile Dockerfile Dockerfile-dev Dockerfile-dev Dockerfile-srt-live Dockerfile-srt-live FAQ.md FAQ.md HOW_IT_WORKS.md HOW_IT_WORKS.md LICENSE LICENSE MAC_DEVELOPMENT.md MAC_DEVELOPMENT.md Makefile Makefile README.md README.md docker-compose.yaml docker-compose.yaml go.mod go.mod go.sum go.sum main.go main.go nginx.conf nginx.conf View all files Repository files navigation * README * Apache-2.0 license [200068510-7c24d5c7-6ba0-44ee-8e60-0f157f990b90] donut is a zero setup required SRT (MPEG-TS) and RTMP to WebRTC bridge powered by Pion. HOW IT WORKS sequenceDiagram actor User box Cornsilk participant browser end User->>+browser: input protocol, host, port, id, and opts User->>+browser: click on [Connect] Note over donut,browser: WebRTC connection setup browser->>+browser: create WebRTC browserOffer browser->>+donut: POST /doSignaling {browserOffer} donut->>+browser: reply WebRTC {serverOffer} Note over donut,browser: WebRTC connection setup loop Async streaming donut--)streaming server: fetchMedia donut--)donut: ffmpeg::libav demux/transcode donut--)browser: sendWebRTCMedia browser--)browser: render audio/video frames User--)browser: watch media end Loading donut docker-compose setup ref: how donut works QUICK START Make sure you have the ffmpeg 5.x.x. You must configure the CGO library path pointing it to ffmpeg 5. export CGO_LDFLAGS="-L/opt/homebrew/Cellar/ffmpeg@5/5.1.4_6/lib/" export CGO_CFLAGS="-I/opt/homebrew/Cellar/ffmpeg@5/5.1.4_6/include/" export PKG_CONFIG_PATH="/opt/homebrew/Cellar/ffmpeg@5/5.1.4_6/lib/pkgconfig" Now you can install and run it: go install github.com/flavioribeiro/donut@latest donut Here are specific instructions to run on MacOS. RUN USING DOCKER-COMPOSE Alternatively, you can use docker-compose to simulate an SRT live transmission and run the donut effortless. make run OPEN THE WEB UI Open http://localhost:8080/demo. You will see two text fields. Fill them with the your streaming info and hit connect. donut docker-compose setup FAQ Please check the FAQ if you're facing any trouble. About donut is a zero setup required SRT+MPEG-TS -> WebRTC Bridge powered by Pion. Topics h264 webrtc live-streaming srt cea608 608 Resources Readme License Apache-2.0 license Activity Stars 197 stars Watchers 10 watching Forks 7 forks Report repository Releases 1 tags Packages 0 No packages published Contributors 4 * @leandromoreira leandromoreira Leandro Moreira * @flavioribeiro flavioribeiro Flavio Ribeiro * @Sean-Der Sean-Der Sean DuBois * @samisb samisb Bryan Samis Languages * Go 86.0% * JavaScript 5.2% * HTML 3.9% * CSS 1.7% * Shell 1.6% * Makefile 0.9% * Dockerfile 0.7% Footer (c) 2024 GitHub, Inc. Footer navigation * Terms * Privacy * Security * Status * Docs * Contact * Manage cookies * Do not share my personal information You can't perform that action at this time.