Build a Stream Server with Nginx
CopyRight 2021-2022 TechProber. All rights reserved.
Maintainer: Kevin Yu (@yqlbu) , Huang (@earrmouth) , and Su (@SuLingGG)
This repo serves to provide the end-users a way to host their stream server easily with Nginx
Both
rtmp
andhttp
are recognized asstream
in Nginx
Since this repository is a clone from the original nginx-http-flv-module, please find the detail usage guide from it
Create the /etc/nginx/
directory
sudo mkdir -p /etc/nginx
cd /etc/nginx
The
nginx.conf
are stored under/etc/nginx/
, you may modify the default path to adjust your need.
Replace ./nginx.conf
with your own configuration, if you plan to add extra configurations such as rewrite-rules
. During the container build period, The nginx.conf
will be copied to the associated path in the container.
The
http-assets
are stored under/etc/nginx/
, you may modify the default path to adjust your need.
Place your http assets under /etc/nginx/
. The data will be mapped to /www
inside the container
# run container locally
make run
# restart container locally
make restart
# run with docker-compose natively
docker-compose up -d
Use the cn-alicloud
as apk source to build the image locally
# run container locally
docker-compose -f ./build/cn-support/docker-compose.yml up -d
# restart container locally
docker-compose -f ./build/cn-support/docker-compose.yml up -d --force-recreate
- nginx - https://nginx.org/download/
- nginx-http-flv-module - https://github.com/winshining/nginx-http-flv-module/archive/refs/tags/
- https://github.com/alfg/docker-nginx-rtmp/blob/master/Dockerfile
- https://github.com/nginxinc/docker-nginx/blob/6f0396c1e06837672698bc97865ffcea9dc841d5/mainline/alpine-perl/Dockerfile
- https://github.com/winshining/nginx-http-flv-module-docker/blob/master/README.CN.md
- https://www.jianshu.com/p/123df9333db0
- https://blog.csdn.net/syy014799/article/details/121885306
- https://blog.csdn.net/a_917/article/details/121473954
- https://hub.docker.com/r/mycujoo/nginx-http-flv-module-docker
- https://blog.csdn.net/a_917/article/details/121473954?spm=1001.2014.3001.5502
- https://blog.csdn.net/a_917/article/details/106709928
- https://blog.csdn.net/Prinz_Corn/article/details/120746676
- https://blog.csdn.net/xjcallen/article/details/107174374