Below is the configuration for the streamer:
[code]
user nobody;
multiple workers works !
worker_processes 2;
error_log logs/error.log;
error_log logs/error.log notice;
error_log logs/error.log info;
pid logs/nginx.pid;
events {
worker_connections 8192;
max value 32768, nginx recycling connections+registry optimization =
this.value * 20 = max concurrent connections currently tested with one worker
C1000K should be possible depending there is enough ram/cpu power
multi_accept on;
}
rtmp {
server {
listen 1935;
chunk_size 4096;
application live365 {
live on;
record off;
record all;
record_path /recordings;
push rtmp://c:/xxxxx/xxx/xxx/Stream1;
push rtmp://a.rtmp.youtube.com/live2/0123-4567-89ab-cdef;
hls on;
hls_path /xxxxx/xxx/xxx/;
hls_fragment 3;
hls_playlist_length 60;
uncomment the line below to prevent people from playing using RTMP
deny play all;
}
}
}
http {
include mime.types;
server {
listen 8080;
location / {
root /nginx/srv/;
index index.html;
add_header Cache-Control no-cache; # Disable cache
}
}
}
[/code]
This seems to be a Windows file permission problem:
from the error log for the streamer:
[code]
2022/08/09 12:45:10 [error] 6236#5696: *568 CreateFile() "C:/xxxxx/xxx/xxx/stream1.m3u8" failed (2: The system cannot find the file specified), client: 192.168.0.1, server: , request: "GET /xxx/stream1.m3u8 HTTP/1.1", host: "", referrer: ""
[/code]
And here's the html for the viewer:
[code]
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>HLS Live Streaming</title>
<link href="/js/video-js.css" rel="stylesheet" />
</head>
<body>
<video
id="my-video"
class="video-js"
controls
preload="auto"
width="1280"
height="720"
data-setup="{}">
<source src="/xxx/stream1.m3u8" type="application/vnd.apple.mpegurl" />
</video>
<script src="/js/video.js"></script>
</body>
</html>
[/code]