Nginx Proxy Manager (NPM)
Proxying live streams through Nginx Proxy Manager
An easy and effective way to set up a reverse proxy for your streaming services is with Nginx Proxy Manager (NPM). This tool provides a user-friendly interface for managing Nginx configurations, including automatic SSL certificates and proxy hosts.
You’ll need to set up NPM on a server that can access your streaming service (like OwnCast). It can be on the same sever or a different one, as long as it can route traffic to your streaming service.
The easiest way to get started is with the official Docker image, which includes all dependencies including nginx, and a web UI for configuration.
Proxying Owncast
You’ll need to setup a proxy host for the web interface of OwnCast, and another for the inbound stream. This walkthrough assumes the default Owncast ports: 8080 for the web interface and 1935 for the stream. Adjust as needed if you’ve changed these in your Owncast configuration.
Web Interface Proxy
- In NPM, go to the “Proxy Hosts” section and click “Add Proxy Host”.
- Enter the domain you want to use for the OwnCast web interface (e.g.,
owncast.yourdomain.com). - Set the scheme to “http” , and in Forward Hostname / IP, enter either:
- the IP address of your Owncast server if Owncast is running on another machine on your network, or
- the Docker service name if NPM and Owncast are running as separate containers on the same server (e.g.,
owncastif your Owncast service is named “owncast” in your docker-compose file).
- Set the forward port to
8080. - Enable “Block Common Exploits” (because why not) and “Websockets Support” (for the chat).
- Under the SSL tab, you can request a Let’s Encrypt certificate for your domain.
- Save the proxy host.
Inbound stream Proxy
- In NPM, go to the “Stream Hosts” section and click “Add Stream”.
- Enter the port you’ll use to stream to (e.g.,
1935). - Set the Forward Hostname / IP, enter either:
- the IP address of your Owncast server if Owncast is running on another machine on your network, or
- the Docker service name if NPM and Owncast are running as separate containers on the same server (e.g.,
owncastif your Owncast service is named “owncast” in your docker-compose file).
- Set the forward port to
1935. - Choose the protocol “TCP”.
- Save the stream host.
If you’re using docker, make sure to add the port you specified in step 2 to the ports section of your docker-compose file, and map it to the same port on the host:
ports:
- "1935:1935"
Then restart your NPM container to apply the changes.
Topic Contacts
@sir-poulpy:matrix.org