![如何在 codeanywhere 上設定 ssh-keygen?](https://rvso.com/image/1525443/%E5%A6%82%E4%BD%95%E5%9C%A8%20codeanywhere%20%E4%B8%8A%E8%A8%AD%E5%AE%9A%20ssh-keygen%EF%BC%9F.png)
如何連接到容器(Linux 和 OSX)的 SSH?
- 打開你的終端
- 輸入 ssh-keygen 您將建立您的公鑰
- 前往 .ssh/id_rsa.pub 並複製整個金鑰
- 在Codeanywhere中,在Container的SSH中,使用指令:cat .ssh/id_rsa.pub
- 使用命令vimauthorized_keys
- (輸入「A」或「I」)將金鑰貼到新行中並儲存(按 ESC 鍵,然後輸入 :wq)
- 在容器資訊中找到 SSH 連接埠號
- 現在,為了連接到您的盒子,您必須使用以下命令建立從本機電腦到容器的隧道:
ssh -P port [email protected] -i id_rsa.pub
我不太明白從第 4 步開始他們給的是什麼。