Skip to content

Instantly share code, notes, and snippets.

@hungtcs
Created August 17, 2022 02:49
Show Gist options
  • Save hungtcs/a7f5422dfa0854a4f21a381ab3560bcd to your computer and use it in GitHub Desktop.
Save hungtcs/a7f5422dfa0854a4f21a381ab3560bcd to your computer and use it in GitHub Desktop.
SSH 使用 HTTP 代理的配置方式
  1. 安装 corkscrew 软件,mac 系统可以直接使用 brew 安装

    brew search corkscrew
    brew install corkscrew
  2. 配置 ssh,编辑 ~/.ssh/config 文件,添加 ProxyCommand 配置

    Host github.com
    HostName github.com
    User git
    IdentityFile ~/.ssh/id_ed25519
    ProxyCommand /opt/homebrew/bin/corkscrew 127.0.0.1 7890 %h %p
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment