October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
DocumentaryTube
Admit one · Blog

How to Run FFmpeg in Docker for a Church’s 24/7 YouTube Stream

A practical guide to running FFmpeg in Docker for a church’s continuous YouTube stream, with RTMPS setup, encoding guidance, recovery limits, monitoring, and copyright planning.
Opened Runtime7 min Written byDocumentaryTube Team
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

You can run FFmpeg in a Docker container to send a church video feed continuously to YouTube Live, provided the host and upload connection remain available. Use YouTube’s RTMPS server URL and stream key, choose an encoding rate your connection can sustain, and configure Docker to restart the container after certain failures. A restart policy is not a stream-health monitor: you must also check YouTube’s preview and health indicators and plan for stream-session boundaries.

What a Dockerized FFmpeg stream can—and cannot—do

FFmpeg reads a video source, encodes or packages its audio and video, and sends the result to YouTube Live. Docker runs FFmpeg in a container, isolating its software and configuration from the host. A Docker restart policy can restart a container after it exits or after Docker restarts, depending on the policy. It cannot guarantee that YouTube is receiving a healthy picture and sound: FFmpeg might remain running while the output is frozen, the connection is rejected, or the stream is otherwise unhealthy.

The complete setup therefore includes more than a container: a YouTube Live Control Room stream, its server URL and key, a suitable video source, a host that stays on, a tested upload connection, and an operator who can check delivery and handle interruptions.

Prepare the YouTube stream and protect its key

  1. Create or schedule the broadcast. In YouTube Studio, open Live Control Room and create or schedule a stream. YouTube’s encoder workflow is to provide the encoder with the stream server URL and stream key, start sending the feed, then inspect the preview. See YouTube’s encoder setup instructions.
  2. Choose RTMPS. Retrieve the RTMPS ingest URL from Live Control Room and use the exact URL YouTube provides. YouTube describes RTMPS as RTMP secured with TLS/SSL and provides instructions for revealing the RTMPS URL in Live Control Room: Encrypt your stream using RTMPS. FFmpeg also documents RTMPS as RTMP over a secure SSL connection: FFmpeg Protocols Documentation.
  3. Copy the stream key as a secret. Treat it like a password. Do not commit it to source control, paste it into a public issue, or expose it in logs or screenshots. Provide it to the container through a protected environment or secret-management mechanism, and restrict access to the host and deployment configuration.
  4. Keep the stream lifecycle in mind. YouTube says streams under 12 hours are automatically archived. That is platform guidance, not a guarantee that a single continuous broadcast will remain one unlimited archive. Plan how staff will manage scheduled broadcasts and any required handoffs or restarts separately from Docker uptime.

Choose a source and encoding settings

Use a source file or live input appropriate to the church’s service. A prerecorded loop and a live camera/mixer feed have different failure modes: a file can reach its end or fail to repeat; a live input can disappear when a capture device, mixer, or source process fails. Test the actual source and full chain before relying on it unattended.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
#1 Best Overall
Sale
KAMRUI Pinova P2 Mini PC, AMD Ryzen 7330U(4 Cores, 8 Threads, Up to 4.3GHz), 16GB RAM 256GB SSD, Zen3 Architecture 7nm Processor, 8MB L3 Smart Cache Mini Computers,Triple 4K Display Home/Business
  • 【AMD Ryzen 7330U】 – The Efficiency-Tuned Powerhouse,AMD Ryzen 7330U (Zen 3, SMT, 4C/8T) in KAMRUI P2 mini PC crushes rivals: Intel i3-10110U (2C/4T, 2019) and N95 (4 efficiency cores, no HT, single-channel memory). Vs predecessor Ryzen 3 4300U (4C/4T): ~50% faster single-core, ~46% multi-core, 8MB L3 cache (vs 4MB). Beats both Intel chips hugely in multi-core, making heavy multitasking, coding, data work smooth at just 15W TDP. High-end power in a cool, efficient box.
  • 【AMD Radeon Graphics】– Triple 4K Vision & Fluidity,The integrated Radeon Graphics (based on the modern Vega architecture with 6 CUs) is a visual beast, outclassing the iGPU offerings from both AMD's prior generation and Intel. The Intel UHD Graphics (i3-10110U/N95) struggles with single-channel memory and low execution units, crippling its gaming performance and barely handling basic 4K video without stuttering. While the older Radeon Vega 5 (4300U) was decent, our 7330U's Radeon Graphics (6 CUs) pushes the boundaries, delivering higher graphics clock speeds (up to 1.8GHz) and significantly better rendering capabilities. It can drive triple 4K@60Hz displays with zero lag, edit photos/videos.
  • 【Generous Storage & Easy Expansion】The KAMRUI Pinova P2 mini desktop computers comes with 16GB LPDDR4X RAM (higher frequency, lower power) for buttery‑smooth multitasking, and a 256GB M.2 SSD for blazing fast boot‑up, quick file transfers, and no more long loading screens. It also features two storage expansion slots (1x M.2 2280 SATA/NVMe PCIe 3.0 slot + 1x M.2 2280 SATA slot), supporting up to 4TB total (not included). You’ll have all the space you need for projects, media, and important data.
  • 【Triple 4K Display Output】The KAMRUI Pinova P2 mini desktop pc is equipped with HDMI 2.0 ×1 + DP 1.4 ×1 + USB 3.2 Gen2 Type‑C ×1 (with DP Alt Mode), enabling simultaneous triple 4K@60Hz output. Whether for home entertainment, remote work, or conference room presentations, it delivers an immersive visual experience. Two USB 3.2 Gen2 Type‑A ports (up to 10Gbps – 21x faster than USB 2.0) make data transfers and device expansion a breeze.
  • 【USB 3.2 Gen2 Type‑C: 10Gbps & Versatile Connectivity】The USB 3.2 Gen2 Type‑C port on the KAMRUI P2 small pc supports 10Gbps data transfer speeds and can also output DisplayPort 1.4 video. Together with Gigabit LAN, Wi‑Fi, and Bluetooth, you get a fast, flexible, and productive connected environment – wired or wireless.

YouTube’s current encoder guidance lists RTMP/RTMPS, H.264, H.265 or AV1 video, up to 60 fps, AAC or MP3 audio, constant bitrate (CBR), and a recommended two-second keyframe interval that should not exceed four seconds. For H.264, its recommended ingest rates include these examples:

Output YouTube-recommended H.264 bitrate
720p at 30 fps 8 Mbps
1080p at 30 fps 14 Mbps
1080p at 60 fps 17 Mbps

These are YouTube’s listed recommendations, not a measurement of your church’s connection or a requirement to use those resolutions. Select a rate the upload link can sustain with headroom for other traffic and normal variation. YouTube recommends testing upload bitrate and monitoring stream health. Review its current encoder settings, bitrates, and resolutions.

Rank #2
GMKtec M5 Ultra Gaming Mini PC Ryzen 7 7730U 32GB RAM 512GB SSD Desktop
  • Office Gaming Mini PC - UPGRADED GMKtec Nucbox M5 Ultra Series is equipped with the powerful AMD Ryzen 7 7730U processor, 8 Cores/16 Threads, Base 2.00GHz (Power Saving Quiet Mode) with Turbo Boost up to 4.50GHz (Performance Mode) in BIOS settings, Based on the ZEN 3+ architecture, this small but powerful mini pc delivers satisfying results in productivity, office work, and gaming. 35% Performance increase over AMD Ryzen 5 7430U/ Ryzen 7 5700U, 5600U, 5560U, 5500U.
  • 32GB DDR4 RAM & 512GB PCIe SSD - Installed with DDR4 32GB RAM Dual Channel (2x16GB), the Nucbox M5 Plus mini pc support expansion to 64GB RAM. Featured with 512GB M.2 2280 PCIe 3.0 SSD, support dual slot expansion to 4TB SSD. (Upgrades not included)
  • DUAL NIC LAN 2.5G RJ45 - Fast Network Speeds: Enjoy up to 2500Mbps data transmission speed without worrying about lagging. Ideal for working, gaming, and surfing the internet. Great for Untangle, Pfsense or as a server office PC.
  • Mini Desktop Computer with 4K Triple Screen Display - Nucbox M5 Ultra integrates AMD Radeon Graphics 8 Cores 2000 MHz GPU to deliver powerful graphics processing power to easily handle the demands of complex design software, 4K@60Hz UHD video editing, and playback. It can connect to 3 display screens simultaneously.
  • Fast Internet WiFi 6E + BT5.2 Connection - GMKtec Mini PC with WiFi-6E Wireless, have 2.5G/5G/6G triple band, more faster and lower latency. Bluetooth 5.2 allowing you more quickly to connect other wireless devices (headset, mouse, keyboard, etc.) Interface features 2*USB3.2 ports, 2*USB2.0 ports, 1*HDMI 2.0 port(4K@60Hz), 1*USB-C port(PD/DP/DATA), 1*DP Port, 1*Audio 3.5mm (HP&MIC), 1*DC Power Port.

For H.264, a two-second keyframe interval at 30 fps corresponds to 60 frames; at 60 fps it corresponds to 120. In FFmpeg, typical controls include a bitrate target, a maximum rate and buffer size for CBR-style output, and a GOP/keyframe interval. Exact options depend on the chosen encoder and source frame rate, so validate the produced stream rather than copying settings blindly.

Build and run the container

The following is a deployment pattern, not a complete copy-and-paste service: the correct input path, encoder, audio mapping, bitrate, and keyframe settings depend on the source and host. Use an FFmpeg image or Dockerfile you trust, pin an image version for repeatability, mount the media read-only where practical, and inject the stream key without embedding it in a public image or committed Compose file.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #3
BOSGAME E5 11 Pro Mini PC, AMD Ryzen 5300U 4C/ 8T, Business Home Office PC
  • 【AMD Ryzen 3 5300U CPU: Outperforms N150 & 3500U】 BOSGAME E5 mini PC is powered by the TSMC 7nm FinFET architecture AMD Ryzen 3 5300U processor (4 Cores, 8 Threads, up to 3.8GHz boost, 6MB total cache). Compared to low-end Intel N150 or 3500U chips which only have 4 single threads and throttle under load, the 5300U delivers over 30% faster multi-core speed. Run 30+ browser tabs, large Excel sheets, and Zoom meetings simultaneously without system lag.
  • 【8GB DDR4 RAM & 256GB NVMe SSD Storage】 Installed with high-speed 8GB DDR4 dual-channel memory and a fast 256GB M.2 2280 SSD, eliminating slow boot times and application loading delays. To accommodate growing data requirements, the upgradeable hardware design features dual SODIMM slots that allow you to expand memory up to 64GB RAM, ensuring smooth operation during heavy multitasking.
  • 【High-Capacity Dual M.2 SSD Storage Expansion】 Never worry about running out of space for your business files. In addition to the pre-installed 256GB system drive, the motherboard houses an extra empty internal M.2 2280 NVMe PCIe 3.0 slot. This allows you to easily add a second solid-state drive for up to an additional 2TB of storage capacity (upgrades not included) without needing to remove or reinstall the original operating system.
  • 【Radeon 6-Core Graphics & Triple 4K Displays】 Integrated with official AMD Radeon Graphics (6 Graphics Cores, 1500 MHz frequency) for casual gaming, photo editing, and crisp 4K media decoding. Featuring 1x HDMI 2.0 port, 1x DisplayPort, and 1x Full-Function Type-C port, the E5 outputs true 4K@60Hz resolution to three monitors at once. This multi-screen setup eliminates constant window-switching for traders, programmers, and office workers.
  • 【Dual 2.5GbE LAN Ports for Advanced Networking】 Experience fast wired network transmission speeds up to 2500Mbps without lagging or buffering. The integration of dual 2.5 Gigabit Ethernet ports (powered by Realtek RTL8125 controller) makes this compact computer an exceptional hardware choice for tech enthusiasts. Easily configure it into software routers, hardware firewalls (pfSense, OpnSense), home NAS servers, or local homelabs.
  1. Install Docker on an always-on host. This may be an existing church computer or a dedicated small computer; a mini PC is not mandatory. A VPS or cloud host is another option if the church prefers hosted compute and can manage its recurring cost and network path.
  2. Make the input available inside the container. Mount a file or provide the live input device/network feed. Check that the container can read it and that the source remains available after host and container restarts.
  3. Run FFmpeg with the YouTube ingest URL and secret key. Map the selected video and audio streams, set the codec and bitrate for the chosen output, use CBR-style rate control where appropriate, and set the keyframe interval to the YouTube recommendation. Use the exact RTMPS URL shown in Live Control Room.
  4. Configure Docker restart behavior. For an unattended service, unless-stopped is a sensible starting point: Docker restarts the container after an exit and after daemon restart, unless an operator deliberately stopped it. The always policy differs in how a manual stop is treated after Docker restarts. Read Docker’s explanation of container restart policies and choose deliberately.
  5. Start the container and verify delivery. Confirm FFmpeg is reading the source and sending output, then inspect YouTube Live Control Room’s preview and stream-health indicators. Do not infer a working broadcast solely from a running container.
  6. Test recovery and operations. Test representative audio and motion, a source interruption, a container exit, and a Docker daemon restart before the live event. Decide who receives alerts, who can access Live Control Room, and how an operator will intervene.

FFmpeg documents an output FIFO recovery example using -attempt_recovery 1 and -recovery_wait_time 1 for trying to recover from temporary failures. This is an option to evaluate for the specific output workflow, not a promise of uninterrupted delivery. Confirm the installed FFmpeg build supports the required protocol and options, and test failure recovery end to end. See FFmpeg’s full documentation.

Monitor the stream, not just the container

  • Container state and logs: Check whether the container is running, whether FFmpeg is reporting errors, and whether its input is advancing. Logs should not reveal the stream key.
  • YouTube preview and health: Verify moving video and audible audio in Live Control Room and watch its stream-health indicators. A process can be alive while its output is frozen or rejected.
  • Source and network: Check that the file, camera, mixer, or upstream feed is still producing content and that upload capacity remains stable under real conditions.
  • Human response: Assign someone to act on alerts or a failed preview. Docker restart policies handle particular exit and daemon events; they do not replace monitoring, alerting, backups, or a response plan.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Plan for copyright and continuous-programming risks

YouTube scans live streams for third-party content. A matched stream can be replaced with a placeholder, interrupted, or terminated if the third-party content continues. Before leaving a church stream unattended, confirm the rights for music and other material in the program. If third-party material is licensed, YouTube says the rights owner may need to add the channel to its Content ID allowlist; a license alone does not ensure automated live playback will avoid interruption. See YouTube’s guidance on copyright issues with live streams.

Rank #4
Sale
GMKtec G3S Mini PC Intel N95 Processor (Up to 3.4GHz) 8GB RAM 256GB M.2 SSD
  • 12th Intel Alder Lake N95 Processor – The GMKtec G3 S Mini PC is powered by the 12th Gen Intel N95 processor with 4 cores, 4 threads, 6MB cache and a burst frequency up to 3.4GHz. Compared with N100/N5105/N5100/N5095, the N95 delivers up to 36% overall performance improvement. Perfect for routine tasks, office work, and home entertainment, this compact mini desktop is more convenient than traditional bulky PCs.
  • 8GB RAM & 256GB SSD Storage – Pre-installed with 8GB DDR4 memory and a fast 256GB M.2 2242 SSD, the G3 S mini desktop offers quicker startup, smoother multitasking, and faster file transfers. Enjoy seamless performance whether you’re working on multiple applications, browsing, or streaming content.
  • Rich Interfaces & Connectivity – The G3 S mini computer comes equipped with USB 3.2 (up to 10Gbps), dual HDMI 2.0 (4K@60Hz), and a 3.5mm audio jack. With support for WiFi 5, Bluetooth 5.0, and Gigabit Ethernet (RJ45 1000MbE), it connects easily with monitors, projectors, printers, office equipment, and other peripherals, making it versatile for both home and business use.
  • Dual 4K Display Support – Featuring upgraded Intel UHD Graphics (up to 1000MHz), the G3 S supports 4K video playback and AV1 decoding for a smooth viewing experience. With dual HDMI outputs, you can connect two 4K@60Hz displays simultaneously, enabling efficient multitasking for work and entertainment.
  • GMKtec WARRANTY - GMKtec offers a 1-year limited GMKtec's warranty for each mini PC, starting from the date of the purchase. All defects due to design and workmanship are covered. With a professional after sales team always ready to attend to your needs, you can simply relax and enjoy your mini PC.

Also distinguish a continuously running encoder from an uninterrupted YouTube broadcast or archive. Docker can keep trying to restart a failed process, but YouTube’s stream/session behavior, source continuity, and copyright enforcement require separate operational planning.

Common problems and fixes

  • YouTube shows no incoming signal: Recheck that the scheduled stream is the one receiving the feed, then verify the exact RTMPS server URL and key from Live Control Room. Confirm FFmpeg’s build supports RTMPS and that the host’s network permits the connection.
  • Stream health is poor or unstable: Reduce resolution, frame rate, or bitrate to a rate the tested upload connection can sustain; check competing network traffic and monitor the health panel. YouTube’s recommended bitrate is not proof that your connection can deliver it reliably.
  • The container keeps restarting: Inspect Docker and FFmpeg logs for missing input files, invalid options, permission problems, or rejected credentials. Restart policy can repeat the failure unless the underlying cause is fixed.
  • Container is running but picture or sound is stuck: Check source progression, audio/video mapping, FFmpeg output, and YouTube’s preview. Add monitoring that detects stale output; container state alone will not identify a healthy audience-facing stream.
  • Stream stops despite a valid setup: Check for YouTube session boundaries and Content ID interruptions, then follow the church’s operator procedure to create or resume the appropriate broadcast and verify the preview again. Do not assume a container restart automatically creates a new YouTube session.

Or let it run in the cloud

If you do not want a church computer, Docker host, or home connection to stay on, StreamNeo is a cloud service for keeping a YouTube channel live from uploaded videos. Upload a recording or build a playlist, add your YouTube stream key once, and go live. Nothing has to stay on at home; it loops uploaded videos in the cloud, supports any quality up to 4K 60fps at one flat price per slot, and automatically recovers if YouTube drops the stream. The first day is free with no card. The monthly option is $9.99 per month. StreamNeo is for YouTube playback of uploaded videos, not a live camera feed. Learn more at StreamNeo, or start the free first day.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Screening Room

  1. Future cities: Urban planners get creativeAdmit one · TechnologyFuture cities: Urban planners get creativeOpened05 OCT 2026Runtime2 min
  2. How the Earth Was Made: Season 1Admit one · ScienceHow the Earth Was Made: Season 1Opened05 OCT 2026Runtime2 min
  3. Inside the Saudi KingdomAdmit one · SocialInside the Saudi KingdomOpened05 OCT 2026Runtime3 min
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.