stream m3u8 url to rtmp in python with pyffmpeg
import pyffmpeg ff = pyffmpeg.FFMpeg() stream = ff.open('http://example.com/live/channel1.m3u8') output = ff.open('rtmp://example.com:1935/live/channel1') while True: frame, val = stream.read() if val == 0: break output.write(frame)