From 7b925a2eb8f9baba1017703ad0698364f1f4fe54 Mon Sep 17 00:00:00 2001 From: blake Date: Sat, 11 Oct 2025 19:10:20 -0500 Subject: [PATCH] 315 current 2025-10-11 19:03:52 25.05.20251006.20c4598 6.12.50 * --- flake.nix | 2 +- .../homelab/services/home/zigbee2mqtt/default.nix | 12 ++++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/flake.nix b/flake.nix index 7a47188..495755e 100644 --- a/flake.nix +++ b/flake.nix @@ -1,6 +1,6 @@ # flake for blakes nixos config # define new devices in outputs -# generation: 314 current 2025-10-11 18:09:02 25.05.20251006.20c4598 6.12.50 * +# generation: 315 current 2025-10-11 19:03:52 25.05.20251006.20c4598 6.12.50 * { description = "blakes nix config"; inputs = { diff --git a/modules/homelab/services/home/zigbee2mqtt/default.nix b/modules/homelab/services/home/zigbee2mqtt/default.nix index 400bef8..6f9bb43 100644 --- a/modules/homelab/services/home/zigbee2mqtt/default.nix +++ b/modules/homelab/services/home/zigbee2mqtt/default.nix @@ -107,6 +107,18 @@ in extraConfig = "proxy_set_header Upgrade $http_upgrade;" + "proxy_set_header Connection upgrade;" + "proxy_set_header Host $host;" + "proxy_set_header X-Real-IP $remote_addr;" + "proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;" + ; + }; + locations."/api" = { + proxyPass = "http://127.0.0.1:${toString cfg.port}/api"; + extraConfig = + "proxy_set_header Host $host;" + + "proxy_http_version 1.1;" + + "proxy_set_header Upgrade $http_upgrade;" + + "proxy_set_header Connection upgrade;" ; }; };