billgreen1
V2EX  ›  SSH

如何在 ssh 登录目标主机后,在目标主机上设置代理,代理地址为登录的机器的 ip?

  •  
  •   billgreen1 · Mar 16, 2021 · 1658 views
    This topic created in 1916 days ago, the information mentioned may be changed or developed.
    ## 需求:
    笔记本 A, 目标主机 B
    希望 ssh 登录 B 后,B 会自动的设置 A 的 ip 为 B 的代理服务器地址

    现在的处理方式是手动查询到 A 的 ip,登录 B 后,shell 里面 export http_proxy=192.168.xx.xx:7890 这样的方式

    由于 A 的 ip 可能每天都会变化,所以希望自动设置

    我用的客户端是 iterm2
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   4009 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 35ms · UTC 00:58 · PVG 08:58 · LAX 17:58 · JFK 20:58
    ♥ Do have faith in what you're doing.