srs-stack icon indicating copy to clipboard operation
srs-stack copied to clipboard

Let oryx backend by srs origin cluster

Open suzp1984 opened this issue 1 year ago • 1 comments

Purpose

Make a single docker image that let Oryx backend by srs origin cluster. @see https://ossrs.net/lts/en-us/docs/v7/doc/origin-cluster

How to make a docker image?

docker build -t [your repo]/oryx:[tag] -f Dockerfile.origin_cluster .

How to run this image by config the count of origin srs instances?

Config the SRS instance count by env ORIGIN_SRS_NUMBER, the default number is 2. e.g. Your docker container has capacity of 6 cpu cores, you want to run 4 SRS origin instances. Let's assume your image name is oryx:origin_cluster, built from above step.

docker run -it --rm --name oryx -p 80:2022 -p 443:2443 -p 1935:1935 -p 8000:8000/udp -p 10080:10080/udp -e ORIGIN_SRS_NUMBER=4 oryx:origin_cluster

TODO

  • [ ] replace the images inside Dockerfile.origin_cluster: zpcat/srs-proxy, zpcat/srs:7-dev

zpcat/srs-proxy is the srs-proxy docker image, check https://github.com/ossrs/srs/pull/4184 zpcat/srs:7-dev is build from latest srs source code, the official srs image need to update.

suzp1984 avatar Nov 01 '24 06:11 suzp1984

When i publish stream it occured error: Screenshot 2025-03-13 at 11 28 39

VyVu avatar Mar 13 '25 04:03 VyVu

When i publish stream it occured error: Screenshot 2025-03-13 at 11 28 39

suzp1984 avatar Apr 07 '25 00:04 suzp1984

Are you using the docker img zpcat/srs-proxy:4 mentioned in this PR?

suzp1984 avatar Apr 07 '25 00:04 suzp1984