Work with config

This commit is contained in:
Nick Mowen 2022-10-26 07:33:27 -06:00
parent 8b4a2353d0
commit 0bd6b3971c
5 changed files with 10 additions and 3 deletions

View File

@ -1,2 +1,2 @@
#!/usr/bin/execlineb -P
/usr/local/go2rtc/sbin/go2rtc -config=/usr/local/go2rtc/go2rtc.yaml
/usr/local/go2rtc/sbin/go2rtc -config=./go2rtc.yaml

View File

@ -1,2 +0,0 @@
webrtc:
listen: ":8555

View File

@ -0,0 +1,2 @@
webrtc:
listen: ":8555"

View File

@ -170,6 +170,12 @@ http {
proxy_set_header Host $host;
}
location /go2rtc {
proxy_pass http://go2rtc/;
proxy_http_version 1.1;
proxy_set_header Host $host;
}
location /live/jsmpeg/ {
proxy_pass http://jsmpeg/;
proxy_http_version 1.1;

View File

@ -17,6 +17,7 @@ export default function WebRtcPlayer({ camera, width, height }) {
}
ws.onmessage = ev => {
const msg = JSON.parse(ev.data);
console.log("For fun " + msg.type + " and a message " + msg.value);
if (msg.type === 'webrtc/candidate') {
pc.addIceCandidate({candidate: msg.value, sdpMid: ''});