Jan Koppe
124e366268
reworks the entire logic how active streams are being tracked. instead of keeping a counter by listening only to srs callback hooks, portier will now actively scrape the http api of known srs nodes to retrieve information about all currently existing streams on a srs node. this prevents portier from being wrong about active stream counts due to drift, and allows us to show more information about stream data to users in the future, as the srs api will also expose information about used codecs, stream resolution and data rates as seen by srs itself. to implement this, the previous remains of celery have been made active again, and it is now required to run exactly one celery beat instance and one or more celery workers beside portier itself. these will make sure that every 5 seconds all srs nodes are actively being scraped, on top of the scrape that is triggered by every srs callback hook. this keeps the data always superfresh. the celery beat function allows us to implement cron-based automation for many other functions (restream, pull, etc) in the future as well, so it's okay to pull in something more heavy here rather than just using a system cron and executing a custom management command all the time. |
||
---|---|---|
docker | ||
source | ||
.gitignore | ||
Dockerfile | ||
LICENSE | ||
README.md | ||
docker-compose.yaml | ||
srs.conf |
README.md
Portier
Portier is a webservice that manages video streaming authorization for SRS and orchestration of surrounding video streaming functions like restreaming, pulling, and recording.
It is based on the Django web framework, and accompanied by concierge, a simple Python agent which will execute the surrounding video streaming functions.
Status
So far I only know of ourselves (Chaos-West TV) as using this software, so it is not yet considered stable. We are using it in production, but we are also actively developing it. Functionality might radically change and break existing workflows, and we might not be able to provide support for it if you chose to run your own instance. However, if you are interested in using it, we are happy to hear from you and help you get started.
Functionality
- User management based on Djangos built-in user management
- Authorization of video streaming requests
- Callbacks from SRS to authorize incoming streams
- Orchestration of video streaming functions
- Restreaming to remote targets (RTMP, SRT)
Planned functionality
- Planned: Analyze incoming streams for quality and health
- Planned: Pulling from remote sources (RTMP, SRT)
- Planned: Recording of streams to an object storage
- Planned: Transcoding of streams and delivery via HLS
- Planned: Switching of streams for MCR functionality
Non-goals
Right now, it is not planned to extend this into some kind of streaming platform like Tw*tch or others. This is a tool to manage and orchestrate video streaming for a specific use case. Think of it as a backoffice swiss-army knife, which we internally use almost always when we are dealing with video streaming to take care of the boring stuff.
License
This software is licensed under the MIT License. See the LICENSE
file for details.