josephnhtam / live-streaming-server-net

A .NET implementation of RTMP live streaming server, supporting HTTP-FLV, WebSocket-FLV, HLS, Kubernetes, cloud storage services integration and more.
https://josephnhtam.github.io/live-streaming-server-net/
MIT License
74 stars 11 forks source link

Upload the files to Azure Blob #19

Closed kasirajansfm closed 2 months ago

kasirajansfm commented 2 months ago

First of all thanks for the wonderful project, its very useful for me.

am using this to stream my desktop and store those stream to Azure blob. Its streaming the desktop, is there any way to upload the files to azure blob.?

josephnhtam commented 2 months ago

Hi @kasirajansfm There will be a package for adding the capability to upload HLS stream to Azure blob storage, but it is not yet published. The codes have been pushed to the develop branch.

kasirajansfm commented 2 months ago

Thanks @josephnhtam, its working for me.

kasirajansfm commented 2 months ago

Hi @josephnhtam on blob its uploaded "https://xxxx.blob.core.windows.net/livevideo/060a8774-2b72-489b-8640-8ab60c898ad4/output.m3u8" to this URL. but i need to upload as "https://xxxx.blob.core.windows.net/livevideo/demo/output.m3u8" like this, is there any possibility to change the identifier.?

josephnhtam commented 2 months ago

Hi @kasirajansfm You can implement the IHlsBlobPathResolver interface to provide a customized path. While the path resolver object instance can be passed to HlsAzureBlobStorageConfiguration.

kasirajansfm commented 2 months ago

image

tried like this, but its not working out.

josephnhtam commented 2 months ago
hlsUploaderConfigurator.AddAzureBlobStorage(blobContainerClient, options =>
    options.BlobPathResolver = new HlsBlobPathResolver()
);

This should work

kasirajansfm commented 2 months ago

Thanks, its worked.