mirror of
https://github.com/sstent/vmimages.git
synced 2026-01-25 14:41:44 +00:00
sync
This commit is contained in:
@@ -33,7 +33,8 @@
|
||||
environment.systemPackages =
|
||||
[ pkgs.socat
|
||||
pkgs.npiperelay
|
||||
pkgs.wsl-ssh-agent-relay];
|
||||
#pkgs.wsl-ssh-agent-relay
|
||||
];
|
||||
|
||||
|
||||
nixpkgs.config.packageOverrides = pkgs: with pkgs; rec {
|
||||
@@ -46,7 +47,20 @@ nixpkgs.config.packageOverrides = pkgs: with pkgs; rec {
|
||||
|
||||
|
||||
|
||||
|
||||
systemd.user.services.ssh-proxy = lib.mkIf (pkgs.stdenv.hostPlatform.isLinux) {
|
||||
Unit = {
|
||||
Description = "WSL Proxy";
|
||||
};
|
||||
Service = {
|
||||
ExecStart = "${pkgs.writeShellScript "start-proxy" ''
|
||||
rm -f /tmp/.ssh-sock
|
||||
setsid ${pkgs.socat}/bin/socat UNIX-LISTEN:/tmp/.ssh-sock,fork EXEC:"/mnt/c/ProgramData/chocolatey/bin/npiperelay.exe -ei -s //./pipe/openssh-ssh-agent",nofork
|
||||
''}";
|
||||
};
|
||||
Install = {
|
||||
WantedBy = [ "default.target" ];
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -80,8 +80,8 @@ programs = {
|
||||
|
||||
#keybase service &
|
||||
|
||||
wsl-ssh-agent-relay start
|
||||
export SSH_AUTH_SOCK=~/.ssh/wsl-ssh-agent.sock
|
||||
# wsl-ssh-agent-relay start
|
||||
# export SSH_AUTH_SOCK=~/.ssh/wsl-ssh-agent.sock
|
||||
ssh-add -l
|
||||
|
||||
'';
|
||||
|
||||
Reference in New Issue
Block a user