nixos/syncthing: fix unix socket curl address (#540735)

This commit is contained in:
Doron Behar
2026-07-11 17:59:50 +00:00
committed by GitHub

View File

@@ -25,10 +25,10 @@ let
if
isUnixGui
# if cfg.guiAddress is a unix socket, tell curl explicitly about it
# note that the dot in front of `${path}` is the hostname, which is
# note that the syncthing.local in front of `${path}` is the hostname, which is
# required.
then
"--unix-socket ${lib.strings.removePrefix "unix://" cfg.guiAddress} http://.${path}"
"--unix-socket ${lib.strings.removePrefix "unix://" cfg.guiAddress} http://syncthing.local${path}"
# no adjustments are needed if cfg.guiAddress is a network address
else
"${cfg.guiAddress}${path}";