Trigger exec_pull on http connection
Hello! Is it possible to trigger exec_pull on http connection? For example, I have following configuration
rtmp {
server {
listen 1935;
application hls {
live on;
hls_path /data;
....
}
}
}
...
http {
server {
listen 8080;
location /hls/ {
alias /data/;
...
}
}
}
I would like to have an exec_pull triggered on HLS http request, i mean if i request for
GET http://<my-host-address>:8080/hls/<stream-name>/index.m3u8
Nginx would try execute command like
ffmpeg -i input-sdp-file.sdp -c:v libx264 -an -f flv rtmp://localhost:1935/hls/$name
first and start streaming from requested http endpoint (and only if it fails return 404),
where $name corresponds to <stream-name> from http request?
Also, I would like to know if it's possible to configure on_play and on_play_done for HLS http connections? I mean, does http request like
GET http://<my-host-address>:8080/hls/<stream-name>/index.m3u8
trigger on_play event, and expiration tirgger on_play_done?
Have you figured out how to do it? @rgordeev I'm interested
still nothing, after 5 years? :)