nginx reverse proxy with rtmp

Yuriy Medvedev medvedev.yp at gmail.com
Sat May 14 08:38:30 UTC 2016


Rtmp it's tcp and you need use nginx as tcp proxy like haproxy
14 мая 2016 г. 3:04 пользователь "Zin Man" <lists at ruby-forum.com> написал:

> I am trying to use nginx reverse proxy to connect to a nginx rtmp server
>
> 2 servers a and b
>
> a = nginx with rtmp ( videos loacated here )
>
> b = nginx reverse proxy
>
> the reverse proxy is working good with http to stream my videos from
> server "a"
>
> but i am not able to use it after installing rtmp on server "a"
>
>
> this is my old server b config
>
> server {
>       listen 80;
>       server_name server_a_name;
>       location / {
>       proxy_pass http://ip of server a/;
>
>                 proxy_set_header Host      $host;
>                 proxy_set_header X-Real-IP $remote_addr;
>       proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
>                 access_log      off;
>                 log_not_found   off;
> =   }
> }
>
> so after installing nginx rtmp on server a i have tried this config on
> server b
>
> rtmp {
>     server {
>             listen 1935;
>     application vod {
>
>         pull rtmp://ip of server a:1935;
> }
>     }
> }
> also tried pull rtmp://ip of server a:1935/vod/;
>
> and this is the config on server a
>
> rtmp
> {
>     server
>     {
>             listen 1935;
>             notify_method get;
>             on_play http://127.0.0.1/vod_handler;
>             application vod
>             {
>                     play /home/files/public_html/cgi-bin/uploads/;
>             }
>     }
> }
> thanks
>
> --
> Posted via http://www.ruby-forum.com/.
>
> _______________________________________________
> nginx mailing list
> nginx at nginx.org
> http://mailman.nginx.org/mailman/listinfo/nginx
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20160514/3a5fad38/attachment.html>


More information about the nginx mailing list