summaryrefslogtreecommitdiff
path: root/flora/services/trainspotter.nix
diff options
context:
space:
mode:
authorstuebinm2022-04-07 21:44:23 +0200
committerstuebinm2022-04-07 22:19:37 +0200
commita22a0346524910c596f97aba955b7346b7479c2d (patch)
tree29385eeb7113ebdf64c990726e1f722b836d0258 /flora/services/trainspotter.nix
parentb7a97a0076d7ce261f67573115e14bbcd0d6d679 (diff)
flora: fix the trainspotter script
Diffstat (limited to 'flora/services/trainspotter.nix')
-rw-r--r--flora/services/trainspotter.nix17
1 files changed, 17 insertions, 0 deletions
diff --git a/flora/services/trainspotter.nix b/flora/services/trainspotter.nix
new file mode 100644
index 0000000..5b81f7e
--- /dev/null
+++ b/flora/services/trainspotter.nix
@@ -0,0 +1,17 @@
+{ config, lib, pkgs, ... }:
+
+{
+ systemd.services.trainspotter = {
+ enable = true;
+ description = "script watching the ilztalbahn gtfs for changes";
+ wantedBy = [ "multi-user.target" ];
+ after = [ "network.target" ];
+ serviceConfig.Type = "simple";
+ path = with pkgs; [ curl libzip mailutils ];
+ script = ''
+ ${pkgs.gauche}/bin/gosh ${pkgs.copyPathToStore ./trainspotter.scm}
+ '';
+ startAt = "daily";
+ };
+
+}