Environment: Ubuntu 20.04.1, Baota Linux Panel, nginx 1.19.6
Build steps
Please install the pagoda panel yourself
1. Compile nginx
To use rtmp, you need to use nginx's rtmp module, so you need to recompile nginx
1. Login panel-software store-nginx-compile and install-add custom module
2. Enter nginx_rtmp_module for module name and description, and fill in --add-module=/www/server/nginx/src/nginx-rtmp-module for parameters.
Pre-script input:
3. Submit, select the module, submit, and wait for the compilation to complete
4. Enter nginx -V in the command line to check whether the installation is successful
2. Configure rtmp
Software Store-nginx-Settings-Configuration Modification
Add rtmp configuration in it
1935193540963
save
3. Configure hls
Baota Panel-Website-Add Site
Please fill in the information here according to the actual situation
After the new creation is completed, enter the site settings-configuration file
Add hls configuration
; }
save
test
rtmp test
Start OBS, set the streaming target, fill in the server address, and write a random streaming key.
Start streaming
Open vlc-Network Stream, enter the set rtmp address, click play to see the picture
HLS test
vlc-network streaming, enter [kbd][http/https]://[server address]/live/[streaming key].m3u8[/kbd], click play to see the screen
Reference articles:
Comments 1 comment
ox