This repository has no description
0

Configure Feed

Select the types of activity you want to include in your feed.

syncthing: generate secrets with generator.path

+7 -2
+7 -2
2configs/syncthing.nix
··· 41 41 secrets."syncthing.key" = { }; 42 42 secrets."syncthing.cert" = { }; 43 43 facts."syncthing.pub" = { }; 44 + generator.path = with pkgs; [ 45 + coreutils 46 + gnugrep 47 + syncthing 48 + ]; 44 49 generator.script = '' 45 - ${pkgs.syncthing}/bin/syncthing generate --config "$secrets" 50 + syncthing generate --config "$secrets" 46 51 mv "$secrets"/key.pem "$secrets"/syncthing.key 47 52 mv "$secrets"/cert.pem "$secrets"/syncthing.cert 48 - cat "$secrets"/config.xml | ${pkgs.gnugrep}/bin/grep -oP '(?<=<device id=")[^"]+' | uniq > "$facts"/syncthing.pub 53 + cat "$secrets"/config.xml | grep -oP '(?<=<device id=")[^"]+' | uniq > "$facts"/syncthing.pub 49 54 ''; 50 55 }; 51 56