workmac: add autossh-based socks proxy job to Hydra

native launchd user job
This commit is contained in:
Trolli Schmittlauch 2025-03-20 15:33:34 +01:00
parent 97d6bf380a
commit 3516b5fb91

View file

@ -94,6 +94,25 @@ in
+ import ./scripts/ssh-loop-fc.nix { inherit pkgs lib; } + import ./scripts/ssh-loop-fc.nix { inherit pkgs lib; }
); );
launchd.agents.hydra_proxy = {
enable = true;
config = {
ProgramArguments = [
"${lib.getExe pkgs.autossh}"
"-M"
"0"
"-D"
"1080"
"-oServerAliveInterval=60"
"-oControlMaster=no"
"-N"
"vpn-whq.services.fcio.net"
];
# TODO: consider socket activation instead
KeepAlive = true;
ThrottleInterval = 60;
};
};
nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "1password-cli" ]; nixpkgs.config.allowUnfreePredicate = pkg: builtins.elem (lib.getName pkg) [ "1password-cli" ];
home.stateVersion = "22.05"; home.stateVersion = "22.05";