From cc31d4a9582913906c5595b2be6e775f17b1018a Mon Sep 17 00:00:00 2001 From: Ludovic <54670129+lbr38@users.noreply.github.com> Date: Tue, 10 Dec 2024 16:28:13 +0100 Subject: [PATCH] patch --- docker/config/nginx/motionui.conf | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/docker/config/nginx/motionui.conf b/docker/config/nginx/motionui.conf index cfa5502..68d8bc3 100644 --- a/docker/config/nginx/motionui.conf +++ b/docker/config/nginx/motionui.conf @@ -84,9 +84,9 @@ server { } # Go2rtc stream access - location ~ /api/stream.mjpeg { + location /api/stream.mjpeg { proxy_pass http://127.0.0.1:1984; - proxy_http_version 1.1; + proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "Upgrade"; proxy_set_header Host $host; @@ -94,8 +94,13 @@ server { } # Go2rtc main page - location ~ /go2rtc { - proxy_pass http://127.0.0.1:1984/; + location /go2rtc { + rewrite ^/go2rtc/?(.*)$ /$1 break; + proxy_pass http://127.0.0.1:1984; + proxy_set_header Host $host; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Forwarded-Proto $scheme; } location ~ \.php$ {