nixos/hosts/astral/links.nix

21 lines
410 B
Nix

{ pkgs, lib, ... }:
let
domain = "nettika.leaf.ninja";
root = "/srv/links";
in {
services.caddy.virtualHosts = {
${domain}.extraConfig = ''
root * ${root}
file_server
'';
"http://localhost:8081".extraConfig = let git = lib.getExe pkgs.git;
in ''
route {
exec {
command ${git} pull --rebase
directory ${root}
}
}
'';
};
}