9 cfg = config.services.fakeroute;
10 routeConf = pkgs.writeText "route.conf" (lib.concatStringsSep "\n" cfg.route);
20 services.fakeroute = {
22 enable = lib.mkEnableOption "the fakeroute service";
24 route = lib.mkOption {
25 type = with lib.types; listOf str;
34 Fake route that will appear after the real
35 one to any host running a traceroute.
45 config = lib.mkIf cfg.enable {
46 systemd.services.fakeroute = {
47 description = "Fakeroute Daemon";
48 after = [ "network.target" ];
49 wantedBy = [ "multi-user.target" ];
54 AmbientCapabilities = [ "CAP_NET_RAW" ];
55 ExecStart = "${pkgs.fakeroute}/bin/fakeroute -f ${routeConf}";
61 meta.maintainers = with lib.maintainers; [ rnhmjoj ];