[英]How to Access Private Subnet EC2 with site to site VPN
If I have an AWS VPC with a private and public subnet.如果我有一个带有私有和公有子网的 AWS VPC。 The public subnet has 1 EC2 instance and the private subnet has 1 EC2 instance as well.
公共子网有 1 个 EC2 实例,私有子网也有 1 个 EC2 实例。 If I do a site to site VPN to my VPC from my work location.
如果我从我的工作地点对我的 VPC 进行站点到站点 VPN。 Can I access my private subnet EC2 instance via ssh using the private ip?
我可以使用私有 ip 通过 ssh 访问我的私有子网 EC2 实例吗? Or do I have to do a Bastian host from my public subnet to access my private subnet EC2 instance?
或者我是否必须从我的公共子网中创建一个 Bastian 主机才能访问我的私有子网 EC2 实例?
Yes, you will be able to ssh to an e2 instance from your on-premise/work location.是的,您将能够从您的本地/工作位置 ssh 到 e2 实例。 You need to configure routing from your work location to reach to the ec2 instance IP.
您需要配置从您的工作位置到 ec2 实例 IP 的路由。 Once that is in place and your security groups allows the incoming connection, then you should be good.
一旦到位并且您的安全组允许传入连接,那么您应该会很好。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.