mirror of
https://github.com/tailscale/tailscale.git
synced 2025-08-14 06:57:31 +00:00
ssh/tailssh: add support for agent forwarding.
Updates #3802 Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
@@ -186,6 +186,10 @@ func (ss *sshSession) launchProcess(ctx context.Context) error {
|
||||
|
||||
ss.cmd = cmd
|
||||
|
||||
if ss.agentListener != nil {
|
||||
cmd.Env = append(cmd.Env, fmt.Sprintf("SSH_AUTH_SOCK=%s", ss.agentListener.Addr()))
|
||||
}
|
||||
|
||||
ptyReq, winCh, isPty := ss.Pty()
|
||||
if !isPty {
|
||||
ss.logf("starting non-pty command: %+v", cmd.Args)
|
||||
|
Reference in New Issue
Block a user