익명 06:14

http 400 error when using nginx reverse proxy

http 400 error when using nginx reverse proxy

I have set up nginx to reverse to several OLD APC webadmin http pages with no issues. when i used modern things like homeassistant things start getting stupid. i am currently getting a 400 error for home assistant with the same config i have for the apc's i am not seeing any thing obvious in the logs. though I am new to nginx so im not sure what im looking for.

upstream homeassistant_app {

   server 10.1.2.136:8123;  # Your application server
}

server {
   listen 80;
   server_name homeassistant.linux2themax.com;

   # Redirect HTTP to HTTPS
   return 301 https://$server_name$request_uri;

}

server {
   listen 443 ssl http2;
   server_name homeassistant.linux2themax.com;

   # SSL configuration (certificates managed separately)
   ssl_certificate /etc/nginx/certs/homeassistant.pem;
   ssl_certificate_key /etc/nginx/certs/homeassistant.key;

   # Security headers
   add_header X-Frame-Options "SAMEORIGIN" always;
   add_header X-Content-Type-Options "nosniff" always;

   # Logging

   access_log /var/log/nginx/homeassistant_access.log;
   error_log /var/log/nginx/homeassistant_error.log debug;

   location / {
       # Forward requests to the backend
       #proxy_http_version 1.1;
       proxy_pass http://homeassistant_app;

       # Pass the original host header to the backend
       proxy_set_header Host $host;

       # Pass the real client IP address
       proxy_set_header X-Real-IP $remote_addr;

       # Append to X-Forwarded-For for proxy chains
       proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;

       # Tell backend the original protocol (http or https)
       proxy_set_header X-Forwarded-Proto $scheme;
   }
}

the error logs are as follows

2026/06/14 10:37:46 [debug] 11037#11037: *1 posix_memalign: 00006203D9074840:4096 @16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "Host" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script var: "MYfullURL.com" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "X-Real-IP" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script var: "CLIENTADDY" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "X-Forwarded-For" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script var: "CLIENTADDY" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "X-Forwarded-Proto" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script var: "https" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "Connection" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "close" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http script copy: "" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:151.
0) Gecko/20100101 Firefox/151.0" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "accept: text/html,application/xhtml+xml,application
/xml;q=0.9,*/*;q=0.8"
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "accept-language: en-US,en;q=0.9" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "accept-encoding: gzip, deflate, br, zstd" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "sec-gpc: 1" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "upgrade-insecure-requests: 1" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "sec-fetch-dest: document" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "sec-fetch-mode: navigate" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "sec-fetch-site: none" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "sec-fetch-user: ?1" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "priority: u=0, i" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: 
"GET / HTTP/1.0^M 
Host: MYfullURL.com^M 
X-Real-IP: CLIENTADDY^M 
X-Forwarded-For: CLIENTADDY^M 
X-Forwarded-Proto: https^M 
Connection: close^M 
user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:151.0) Gecko/20100101 Firefox/151.0^M 
accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8^M 
accept-language: en-US,en;q=0.9^M 
accept-encoding: gzip, deflate, br, zstd^M 
sec-gpc: 1^M 
upgrade-insecure-requests: 1^M 
sec-fetch-dest: document^M 
sec-fetch-mode: navigate^M 
sec-fetch-site: none^M 
sec-fetch-user: ?1^M 
priority: u=0, i^M 
^M 
"
2026/06/14 10:37:46 [debug] 11037#11037: *1 http cleanup add: 00006203D91BA330 
2026/06/14 10:37:46 [debug] 11037#11037: *1 get rr peer, try: 1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 stream socket 35 
2026/06/14 10:37:46 [debug] 11037#11037: *1 epoll add connection: fd:35 ev:80002005 
2026/06/14 10:37:46 [debug] 11037#11037: *1 connect to MYSERVER:8123, fd:35 #2 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream connect: -2 
2026/06/14 10:37:46 [debug] 11037#11037: *1 posix_memalign: 00006203D91A0870:128 @16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 event timer add: 35: 60000:412083186 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http finalize request: -4, "/?" a:1, c:2 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http request count:2 blk:0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame complete pos:00006203D921FC81 end:00006203D921FC8E 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame type:8 f:0 l:4 sid:3 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 WINDOW_UPDATE frame sid:3 window:12451840 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame complete pos:00006203D921FC8E end:00006203D921FC8E 
2026/06/14 10:37:46 [debug] 11037#11037: *1 delete posted event 00006203D91C3478 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http run request: "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream check client, write event:0, "/" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 read handler 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_read: 9 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_read: -1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_get_error: 2 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame type:4 f:1 l:0 sid:0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 SETTINGS frame
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame complete pos:00006203D921FC8E end:00006203D921FC8E 
2026/06/14 10:37:46 [debug] 11037#11037: *1 delete posted event 00006203D91C3478 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http run request: "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream check client, write event:0, "/" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 read handler 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_read: 9 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_read: -1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_get_error: 2 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame type:4 f:1 l:0 sid:0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 SETTINGS frame 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame complete pos:00006203D921FB59 end:00006203D921FB59 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream request: "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream send request handler 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream send request 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream send request body 
2026/06/14 10:37:46 [debug] 11037#11037: *1 chain writer buf fl:1 s:537 
2026/06/14 10:37:46 [debug] 11037#11037: *1 chain writer in: 00006203D91BA370 
2026/06/14 10:37:46 [debug] 11037#11037: *1 writev: 537 of 537 
2026/06/14 10:37:46 [debug] 11037#11037: *1 chain writer out: 0000000000000000 
2026/06/14 10:37:46 [debug] 11037#11037: *1 event timer del: 35: 412083186 
2026/06/14 10:37:46 [debug] 11037#11037: *1 event timer add: 35: 60000:412083187 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream request: "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream process header 
2026/06/14 10:37:46 [debug] 11037#11037: *1 malloc: 00006203D9075850:4096 
2026/06/14 10:37:46 [debug] 11037#11037: *1 recv: eof:0, avail:-1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 recv: fd:35 178 of 4096 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy status 400 "400 Bad Request" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "Content-Type: text/plain; charset=utf-8" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "Content-Length: 16" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "Date: Sun, 14 Jun 2026 10:37:46 GMT" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header: "Server: Python/3.13 aiohttp/3.13.2" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy header done 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 header filter
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 table size update: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: ":status: 400" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: "server: nginx" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: "date: Sun, 14 Jun 2026 10:37:46 GMT" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: "content-type: text/plain; charset=utf-8" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: "content-length: 16" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: "x-frame-options: SAMEORIGIN" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 output header: "x-content-type-options: nosniff" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2:3 create HEADERS frame 00006203D9074D90: len:104 fin:0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http cleanup add: 00006203D9074E88 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame out: 00006203D9074D90 sid:3 bl:1 len:104 
2026/06/14 10:37:46 [debug] 11037#11037: *1 malloc: 00006203D925FB60:16384 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL buf copy: 9 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL buf copy: 104 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2:3 HEADERS frame 00006203D9074D90 was sent 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame sent: 00006203D9074D90 sid:3 bl:1 len:104 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http cacheable: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http proxy filter init s:400 h:0 c:0 l:16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream process upstream 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe read upstream: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe preread: 16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe buf free s:0 t:1 f:0 00006203D9075850, pos 00006203D90758F2, size:
16 file: 0, size: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe length: 16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 input buf #0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe write downstream: 1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe write downstream flush in 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http output filter "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http copy filter: "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http postpone filter "/?" 00006203D9074FC8 
2026/06/14 10:37:46 [debug] 11037#11037: *1 write new buf t:1 f:0 00006203D9075850, pos 00006203D90758F2, size: 16 
file: 0, size: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http write filter: l:0 f:0 s:16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http copy filter: 0 "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 pipe write downstream done
2026/06/14 10:37:46 [debug] 11037#11037: *1 event timer: 35, old: 412083187, new: 412083190 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream exit: 0000000000000000 
2026/06/14 10:37:46 [debug] 11037#11037: *1 finalize http upstream request: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 finalize http proxy request 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free rr peer 1 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 close http upstream connection: 35 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D91A0870, unused: 48 
2026/06/14 10:37:46 [debug] 11037#11037: *1 event timer del: 35: 412083187 
2026/06/14 10:37:46 [debug] 11037#11037: *1 reusable connection: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http upstream temp fd: -1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http output filter "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http copy filter: "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http postpone filter "/?" 00007FFC41F3B1C0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 write old buf t:1 f:0 00006203D9075850, pos 00006203D90758F2, size: 16 
file: 0, size: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 write new buf t:0 f:0 0000000000000000, pos 0000000000000000, size: 0 f
ile: 0, size: 0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http write filter: l:1 f:0 s:16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http write filter limit 2097152 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 send chain: 00006203D9074FB8 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2:3 windows: conn:12582912 stream:12582912 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2:3 create DATA frame 00006203D9074D90: len:16 flags:1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame out: 00006203D9074D90 sid:3 bl:0 len:16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL buf copy: 9 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL buf copy: 16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL to write: 138 
2026/06/14 10:37:46 [debug] 11037#11037: *1 SSL_write: 138 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2:3 DATA frame 00006203D9074D90 was sent 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 frame sent: 00006203D9074D90 sid:3 bl:0 len:16 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http write filter 0000000000000000 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http copy filter: 0 "/?" 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http finalize request: 0, "/?" a:1, c:1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http request count:1 blk:0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 close stream 3, queued 0, processing 1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http close request 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http log handler
2026/06/14 10:37:46 [debug] 11037#11037: *1 geoip2 http log handler 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D9075850 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D91B8460, unused: 8 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D91B9470, unused: 14 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D9074840, unused: 1637 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D906E920, unused: 527 
2026/06/14 10:37:46 [debug] 11037#11037: *1 post event 00006203D91FBCB0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 delete posted event 00006203D91FBCB0 
2026/06/14 10:37:46 [debug] 11037#11037: *1 http2 handle connection handler 
2026/06/14 10:37:46 [debug] 11037#11037: *1 event timer add: 34: 75000:412098190 
2026/06/14 10:37:46 [debug] 11037#11037: *1 reusable connection: 1 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D91C3330, unused: 3472 
2026/06/14 10:37:46 [debug] 11037#11037: *1 free: 00006203D925FB60 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 idle handler 
2026/06/14 10:37:47 [debug] 11037#11037: *1 reusable connection: 0 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D91C3330:4096 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 read handler 
2026/06/14 10:37:47 [debug] 11037#11037: *1 SSL_read: 164 
2026/06/14 10:37:47 [debug] 11037#11037: *1 SSL_read: -1 
2026/06/14 10:37:47 [debug] 11037#11037: *1 SSL_get_error: 2 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 frame type:1 f:25 l:142 sid:5 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 HEADERS frame sid:5 depends on 0 excl:0 weight:22 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D906E920:1024 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D906C120:512 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D91B8460:4096 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D91B9470:4096 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 event timer del: 34: 412098190 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 2 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: ":method: GET" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 5 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:9 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http uri: "/favicon.ico" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http args: ""
2026/06/14 10:37:47 [debug] 11037#11037: *1 http exten: "ico" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: ":path: /favicon.ico" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 74 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: ":authority: MYfullURL.com" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 7 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: ":scheme: https" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 73 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:151.0) Ge
cko/20100101 Firefox/151.0" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 72 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:53 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table add: "accept: image/avif,image/webp,image/png,image/svg+xml
,image/*;q=0.8,*/*;q=0.5" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table account: 107 free:3288 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "accept: image/avif,image/webp,image/png,image/svg+xml,im
age/*;q=0.8,*/*;q=0.5" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 72 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "accept-language: en-US,en;q=0.9" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 71 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "accept-encoding: gzip, deflate, br, zstd" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 70 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "sec-gpc: 1" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 51 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:28 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table add: "referer: https://MYfullURL.com/" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table account: 78 free:3181 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "referer: https://MYfullURL.com/" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 69 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:4 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table add: "sec-fetch-dest: image" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table account: 51 free:3103 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "sec-fetch-dest: image" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 69
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:5 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table add: "sec-fetch-mode: no-cors" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table account: 53 free:3052 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "sec-fetch-mode: no-cors" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 69 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:8 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table add: "sec-fetch-site: same-origin" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table account: 57 free:2999 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "sec-fetch-site: same-origin" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed name: 68 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 encoded string, len:3 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table add: "priority: u=6" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 table account: 43 free:2942 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "priority: u=6" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 get indexed header: 68 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header: "te: trailers" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 request line: "GET /favicon.ico HTTP/2.0" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 0 
2026/06/14 10:37:47 [debug] 11037#11037: *1 rewrite phase: 1 
2026/06/14 10:37:47 [debug] 11037#11037: *1 test location: "/" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 using configuration "/" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http cl:-1 max:1048576 
2026/06/14 10:37:47 [debug] 11037#11037: *1 rewrite phase: 3 
2026/06/14 10:37:47 [debug] 11037#11037: *1 post rewrite phase: 4 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 5 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 6 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 7 
2026/06/14 10:37:47 [debug] 11037#11037: *1 access phase: 8 
2026/06/14 10:37:47 [debug] 11037#11037: *1 access phase: 9 
2026/06/14 10:37:47 [debug] 11037#11037: *1 access phase: 10
2026/06/14 10:37:47 [debug] 11037#11037: *1 access phase: 11 
2026/06/14 10:37:47 [debug] 11037#11037: *1 post access phase: 12 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 13 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 14 
2026/06/14 10:37:47 [debug] 11037#11037: *1 generic phase: 15 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http init upstream, client timer: 0 
2026/06/14 10:37:47 [debug] 11037#11037: *1 post event 00006203D91C3478 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D9074840:4096 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "Host" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script var: "MYfullURL.com" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "X-Real-IP" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script var: "CLIENTADDY" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "X-Forwarded-For" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script var: "CLIENTADDY" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "X-Forwarded-Proto" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script var: "https" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "Connection" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "close" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http script copy: "" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:151.
0) Gecko/20100101 Firefox/151.0" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "accept: image/avif,image/webp,image/png,image/svg+x
ml,image/*;q=0.8,*/*;q=0.5" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "accept-language: en-US,en;q=0.9" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "accept-encoding: gzip, deflate, br, zstd" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "sec-gpc: 1" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "referer: https://MYfullURL.com/" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "sec-fetch-dest: image" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "sec-fetch-mode: no-cors" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "sec-fetch-site: same-origin" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "priority: u=6" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: 
"GET /favicon.ico HTTP/1.0^M 
Host: MYfullURL.com^M
X-Real-IP: CLIENTADDY^M 
X-Forwarded-For: CLIENTADDY^M 
X-Forwarded-Proto: https^M 
Connection: close^M 
user-agent: Mozilla/5.0 (X11; Linux x86_64; rv:151.0) Gecko/20100101 Firefox/151.0^M 
accept: image/avif,image/webp,image/png,image/svg+xml,image/*;q=0.8,*/*;q=0.5^M 
accept-language: en-US,en;q=0.9^M 
accept-encoding: gzip, deflate, br, zstd^M 
sec-gpc: 1^M 
referer: https://MYfullURL.com/^M 
sec-fetch-dest: image^M 
sec-fetch-mode: no-cors^M 
sec-fetch-site: same-origin^M 
priority: u=6^M 
^M 
" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http cleanup add: 00006203D91B9440 
2026/06/14 10:37:47 [debug] 11037#11037: *1 get rr peer, try: 1 
2026/06/14 10:37:47 [debug] 11037#11037: *1 stream socket 35 
2026/06/14 10:37:47 [debug] 11037#11037: *1 epoll add connection: fd:35 ev:80002005 
2026/06/14 10:37:47 [debug] 11037#11037: *1 connect to MYSERVER:8123, fd:35 #3 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream connect: -2 
2026/06/14 10:37:47 [debug] 11037#11037: *1 posix_memalign: 00006203D91A0870:128 @16 
2026/06/14 10:37:47 [debug] 11037#11037: *1 event timer add: 35: 60000:412084044 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http finalize request: -4, "/favicon.ico?" a:1, c:2 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http request count:2 blk:0 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 frame complete pos:00006203D921FBE7 end:00006203D921FBF4 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 frame type:8 f:0 l:4 sid:5 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 WINDOW_UPDATE frame sid:5 window:12451840 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 frame complete pos:00006203D921FBF4 end:00006203D921FBF4 
2026/06/14 10:37:47 [debug] 11037#11037: *1 delete posted event 00006203D91C3478 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http run request: "/favicon.ico?" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream check client, write event:0, "/favicon.ico" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream request: “/favicon.ico?”

2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream send request handler 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream send request 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream send request body 
2026/06/14 10:37:47 [debug] 11037#11037: *1 chain writer buf fl:1 s:554 
2026/06/14 10:37:47 [debug] 11037#11037: *1 chain writer in: 00006203D91BA380 
2026/06/14 10:37:47 [debug] 11037#11037: *1 writev: 554 of 554 
2026/06/14 10:37:47 [debug] 11037#11037: *1 chain writer out: 0000000000000000 
2026/06/14 10:37:47 [debug] 11037#11037: *1 event timer del: 35: 412084044 
2026/06/14 10:37:47 [debug] 11037#11037: *1 event timer add: 35: 60000:412084045 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream request: "/favicon.ico?" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http upstream process header 
2026/06/14 10:37:47 [debug] 11037#11037: *1 malloc: 00006203D9075850:4096 
2026/06/14 10:37:47 [debug] 11037#11037: *1 recv: eof:0, avail:-1 
2026/06/14 10:37:47 [debug] 11037#11037: *1 recv: fd:35 178 of 4096 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy status 400 "400 Bad Request" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "Content-Type: text/plain; charset=utf-8" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "Content-Length: 16" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "Date: Sun, 14 Jun 2026 10:37:47 GMT" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header: "Server: Python/3.13 aiohttp/3.13.2" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http proxy header done 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 header filter 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: ":status: 400" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: "server: nginx" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: "date: Sun, 14 Jun 2026 10:37:47 GMT" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: "content-type: text/plain; charset=utf-8" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: "content-length: 16" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: "x-frame-options: SAMEORIGIN" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 output header: "x-content-type-options: nosniff" 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2:5 create HEADERS frame 00006203D9074DC0: len:103 fin:0 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http cleanup add: 00006203D9074EA8 
2026/06/14 10:37:47 [debug] 11037#11037: *1 http2 frame out: 00006203D9074DC0 sid:5 bl:1 len:103 


Top Answer/Comment:

https://community.home-assistant.io/t/connection-issues-with-nginx-proxy/780195/6 specifically answered the issue with homeassistant.

'location /api/websocket {' Specifically had to be added for completion of login to the system as that covers the websockets that HA uses to run.

proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; for the main location block in my above config is specifically required to handle the 400 error as well as going in to HA and telling it that there was a proxy host.

I suspect that things like zwave js ui and esp home will need separate tweaks as well as they did not like the stock settings either. that is a problem for another day though.

Thank you @HBruijn for pointing me in the right direction as i had no idea what to search for to start tracking this down. the HA logs stated both proxy errors and a specific login error i could search for and find the above thread and several others that got things sorted out. since it was happening to multiple apps and using that generic error my frustration blinded me.

상단 광고의 [X] 버튼을 누르면 내용이 보입니다