diff --git a/nixos/linux.nix b/nixos/linux.nix index fe8a5e9..ab042cb 100644 --- a/nixos/linux.nix +++ b/nixos/linux.nix @@ -30,6 +30,17 @@ }; pullomatic = "${pullomaticPkg}/bin/pullomatic"; + + writeShellScriptBinInRepoRoot = name: script: pkgs.writeShellScriptBin name '' + cd `${pkgs.git}/bin/git rev-parse --show-toplevel` + ${script} + ''; + + start-arion-run = writeShellScriptBinInRepoRoot "start-arion-run" '' + cd arion/ + ${pkgs.arion}/bin/arion down + ${pkgs.arion}/bin/arion up + ''; in { imports = [ (import ./cloned_repos {inherit pkgs pullomatic lib;}) @@ -43,17 +54,6 @@ in { age.secrets.nearlyfreespeech.file = ./secrets/nearlyfreespeech.age; age.secrets.nearlyfreespeech.owner = "root"; - writeShellScriptBinInRepoRoot = name: script: pkgs.writeShellScriptBin name '' - cd `${pkgs.git}/bin/git rev-parse --show-toplevel` - ${script} - ''; - - start-arion-run = writeShellScriptBinInRepoRoot "start-arion-run" '' - cd arion/ - ${pkgs.arion}/bin/arion down - ${pkgs.arion}/bin/arion up - ''; - environment.systemPackages = [ ddnsPkg pullomaticPkg