This commit is contained in:
2023-02-21 10:58:49 -05:00
parent 698142aec9
commit c4af7d5be4

View File

@@ -28,24 +28,28 @@
}; };
environment.systemPackages = environment.systemPackages =
[ pkgs.socat ]; [ pkgs.socat pks.npiperelay];
# pkgs.npiperelay
pkgs.callPackage ../../pkgs/npiperelay/ {};
#npiperelay = import ../../pkgs/npiperelay/flake.nix { inherit pkgs; };
systemd.user.services.ssh-proxy = { packageOverrides = pkgs: with pkgs; rec {
description = "WSL Proxy"; npiperelay = callPackage ../../pkgs/npiperelay { inherit pkgs; };
serviceConfig = {
ExecStart = "${pkgs.writeShellScript "start-proxy" ''
rm -f /tmp/.ssh-sock
setsid ${pkgs.socat}/bin/socat UNIX-LISTEN:/tmp/.ssh-sock,fork EXEC:"/run/current-system/sw/bin/npiperelay.exe -ei -s //./pipe/openssh-ssh-agent",nofork
''}";
};
wantedBy = [ "default.target" ];
}; };
#pkgs.callPackage ./npiperelay.nix {};
systemd.services.nixs-wsl-systemd-fix = { systemd.services.nixs-wsl-systemd-fix = {
description = "Fix the /dev/shm symlink to be a mount"; description = "Fix the /dev/shm symlink to be a mount";