syncthing: fix vars generator not working with latest Syncthing

This commit is contained in:
Michael Hoang
2025-09-16 14:08:10 +02:00
parent 8a1f924f72
commit 1f9b44a4ad

View File

@@ -11,7 +11,9 @@
pkgs.syncthing
];
script = ''
syncthing generate --config "$out"
export TMPDIR=/tmp
TEMPORARY=$(mktemp -d)
syncthing generate --config "$out" --data "$TEMPORARY"
mv "$out"/key.pem "$out"/key
mv "$out"/cert.pem "$out"/cert
cat "$out"/config.xml | grep -oP '(?<=<device id=")[^"]+' | uniq > "$out"/id