Learn about Centmin Mod LEMP Stack today
Register Now

Nginx Best way to stream a video file from a server.

Discussion in 'Install & Upgrades or Pre-Install Questions' started by hitman, Dec 27, 2018.

  1. hitman

    hitman Member

    126
    11
    18
    Jul 18, 2014
    Ratings:
    +15
    Local Time:
    1:32 AM
    • CentOS Version: CentOS 7 64bit ?
    • Centmin Mod Version Installed: 123.09beta01
    • Nginx Version Installed: 1.15.7
    • PHP Version Installed: 5.6.x

    Hello everyone and Merry Christmas and a Happy New Year.
    I have some videos in a server which is running centminmod and I would like to stream these videos. So I have created a very simple flask app that takes the video file places it in a directory and I have access to it through http.

    What is the best way to stream this file?
    I read about the RTMP and how i can set it up to stream video files from the server. If that is the case how do i recompile nginx in centminmod to add the module of RTMP?
    Any suggestion you might have please share

    thank you for your time :D
     
  2. eva2000

    eva2000 Administrator Staff Member

    41,369
    9,287
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +14,245
    Local Time:
    8:32 AM
    Nginx 1.17.x
    MariaDB 5.5/10.x
    stream as in live streaming or you mean serving non-live video i.e. mp4 ? live streaming needs RTMP while non-live can do via nginx mp4/flv optional nginx modules - nice discussion at https://community.centminmod.com/threads/help-with-a-solution-for-video-streaming.15538/

    Centmin Mod 123.09beta01 has NGINX_VIDEO option when enabled will auto enabling additional nginx modules outlined at https://community.centminmod.com/threads/add-nginx_video-control-variable-in-123-09beta01.15540/

    Then with nginx modules in place, configuration of nginx is left to end users to figure out as how to serve the videos.
     
    • Like Like x 1