Deploy Nginx RTMP
A simple self-hosted streaming live room.
nginx-rtmp
Just deployed
Deploy and Host Nginx RTMP on Railway
Nginx RTMP is an Nginx-based media streaming server for live video delivery. It supports RTMP publishing and HLS playback, making it suitable for receiving live streams from tools such as OBS and serving them to compatible video players. The nginx-rtmp-module also supports H264/AAC streaming and other live-media features.
About Hosting Nginx RTMP
Hosting Nginx RTMP on Railway involves deploying the tiangolo/nginx-rtmp:latest Docker image as a Railway service. The configuration listens for RTMP streams on port 1935 and serves the HLS output and web content over HTTP on port 80. Railway provides the networking layer needed to expose both endpoints publicly. HLS segments are generated under /tmp/hls, so persistent storage is not required for the documented configuration. No database or runtime environment variables are required. Once deployed, you can generate a Railway domain for HTTP access and use a TCP proxy for RTMP publishing.
Common Use Cases
- Live video streaming from OBS or other RTMP-compatible broadcasting software
- Self-hosted HLS streaming for web-based video playback
- Development and testing of RTMP and HLS streaming workflows
Dependencies for Nginx RTMP
tiangolo/nginx-rtmp:latestDocker image- OBS Studio or another RTMP-compatible streaming client
Deployment Dependencies
Implementation Details
Docker
The template uses the following Docker image:
tiangolo/nginx-rtmp:latest
Railway deploys the prebuilt image directly, so no custom build or start command is required.
Public Networking
Configure the following ports:
| Protocol | Proxy Type | Target Port | Purpose |
|---|---|---|---|
| HTTP | HTTP Proxy | 80 | Web content and HLS playback |
| RTMP | TCP Proxy | 1935 | RTMP stream ingestion |
After deployment, generate a Railway domain for port 80. For RTMP publishing, use the TCP proxy generated for port 1935.
Streaming Configuration
The RTMP application is available at the /live path. A compatible streaming client can publish using an endpoint similar to:
rtmp://:/live
The stream key is appended to the RTMP URL when publishing.
HLS output is generated at:
/tmp/hls
and can be accessed through the HTTP service using:
https:///hls/stream.m3u8
The supplied configuration has recording disabled, so no persistent volume is required.
Why Deploy Nginx RTMP on Railway?
Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.
By deploying Nginx RTMP on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.
Template Content
nginx-rtmp
tiangolo/nginx-rtmp:latest