mediacms-io / mediacms

MediaCMS is a modern, fully featured open source video and media CMS, written in Python/Django and React, featuring a REST API.
https://mediacms.io
GNU Affero General Public License v3.0
2.7k stars 498 forks source link

Explore options to integrate a live streaming solution #245

Closed mgogoulos closed 1 year ago

mgogoulos commented 3 years ago

Describe the feature you'd like Explore which of the following projects could be integrated to MediaCMS to provide live streaming too

MyBlood commented 2 years ago

Describe the feature you'd like Explore which of the following projects could be integrated to MediaCMS to provide live streaming too

Livekit and Owncast look great. But alas, from a developer's point of view, I can't say which is better.

KyleMaas commented 1 year ago

I'd be really interested in seeing this feature as well.

KyleMaas commented 1 year ago

OpenStreamingPlatform looks to be fairly easy to integrate using the OAuth2 support and Webhooks. If I understand it correctly, the MediaCMS Django instance would need to be set up as an OAuth2 provider so logins could be used across both platforms:

https://django-oauth-toolkit.readthedocs.io/en/latest/tutorial/tutorial_01.html

From there, MediaCMS would need to implement a Webhook endpoint for OSP to catch new videos, comments, etc. and add them as uploaded videos:

https://open-streaming-platform.readthedocs.io/en/latest/usage/webhooks.html

KyleMaas commented 1 year ago

Owncast can also be set up with a Webhook endpoint:

https://owncast.online/thirdparty/webhooks/

However, as far as I can tell, it only supports one streaming user - the Owncast administrator. This could work for situations where MediaCMS only has one poster (internal corporate environment, for example) but may not work as well for a publicly-accessible instance where more than one user can post media to the site and would want to be able to live stream.

KyleMaas commented 1 year ago

LiveKit looks to be much lower-level as far as implementation. Does not include any functionality for chats or stream recording as far as I can tell, and user authentication is at a layer above the scope of the project. It can be controlled using server APIs, and there is a Python SDK project available for it:

https://github.com/tradablebits/livekit-server-sdk-python

Also uses Webhooks for communicating back:

https://docs.livekit.io/server/webhooks/