Not Sure How To Articulate This Problem


So, I am working on a program that requires incoming http and rtmp to the server to be processed by LXD containers on the same server. I can forward the incoming rtmp to the correct container where the rtmp segments are being stored as .ts segments and the m3u8 file. HAproxy handles this fine.

My problem is the getting the stream ID play. This is done by http and works fine without using containers.
However does not work from the container.

The following network screen grab are for the working case that is not using containers. Can this be duplicated using haproxy in the case of using containers to store the video and play it?

Is there other information you need to answer this, please let me know.




Here is the current haproxy.cfg I am using to forward the rtmp requests. I have redacted the host IP for obvious reasons. Note that I can ping out from the containers to the host as well as to the internet (yahoo, google, etc).


This is clearly not the entire configuration, as you also need the TCP port 3000 forwarding, right?

Please share the entire configuration and logs.


So, I have a REACT application video player on the host that uses port 3000. But now I am wondering if I should create another container and install the player there?


The Media Server appears to be working properly as I can see the live video segments being created. The broadcaster points his rtmp to the host server, for example rtmp://”host IP”:1935/container1 and is forwarded via host HAproxy to container1, port 1935 where the media server is listening.

I can create an MP4 from the .ts segments that the media server creates, using ffmpeg which pretty much proves the front end of this process is working.

However I need to be able to view the video from the internet to confirm things are working from beginning to end, end being viewing the broadcast from the internet.

My next experiment will be to use iptables in the host to port-forward incoming http://server IP/container1 on port 80 to the HAPROXY container where HAproxy will then forward the request to either the video player on the host, or the player in it’s own container?

I don’t know if having the video player in its own container buys me anything?

Note that I am doing this locally. This configuration is for testing only. Eventually I will be using CDN to distribute the live stream.

So disclaimer, I am not a programmer at all. I am technical savvy and just trying to get an idea to work.

Does all this make sense?