工作站 -> 本地 LXC -> AWS
我已将 .ssh 密钥和配置从主工作站复制到其上的 LXD 容器中。我还清除了我的 ip 表,这是 docker 的一个问题,我相信它阻止了我的网桥访问互联网。我现在可以访问了。
不幸的是,当我尝试 SSH 时连接超时:(
OpenSSH_8.2p1 Ubuntu-4ubuntu0.3, OpenSSL 1.1.1f 31 Mar 2020
debug1: Reading configuration data /root/.ssh/config
debug1: /root/.ssh/config line 16: Applying options for rabbit-dev
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no
files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug1: Connecting to ec2-##-###-###-###.compute-1.amazonaws.com [##.###.###.###] por
t 22.
debug1: connect to address ##.###.###.### port 22: Connection timed out
ssh: connect to host ec2-##-###-###-###.compute-1.amazonaws.com port 22: Connection t
imed out
我的 ~/.ssh/config 包含
Host rabbit-dev
HostName ec2-##-###-###-###.compute-1.amazonaws.com
IdentityFile ~/.ssh/dev_company.pem
LocalForward 11003 rabbitmq.internal.dev.company.com:80
LocalForward 11004 rabbitmq.internal.dev.company.com:5672
User ec2-user
IdentitiesOnly yes