Вопрос

I've been looking around, but haven't been able to find much. It all seems to assume that I'm trying to access a single EC2 instance under a VPC.

The scenario: We have one EC2 medium under a VPC which is hosting several websites (running Windows), and we need to launch a Linux EC2 under that same VPC to run a forum for one of the sites. It's going to run at domain.com/forum where domain.com is hosted on the Windows server. I'm going to try using a reverse proxy in IIS to get the forum, but we need to access it first. Would a NAT instance be what I'm looking for?

Any ideas?

Это было полезно?

Решение

You don't need a NAT. You would need a NAT only if you had only one server in the public subnet, and the other servers behind the private subnet. As you have already one server serving websites, I can assume you have a VPC with either public subnet or public subnet + private subnet.

For more info, see http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/VPC_NAT_Instance.html

Anyway, just launch your linux instance and make sure to configure your HTTPD (Apache VirtualHost or Nginx location) to respond to requests addressed to your domain subfolder correctly.

Другие советы

Start your linux instance in the same subnet as the windows instance. These two instances will be able to communicate using their local ips. The linux instance will get an IP and default gateway the same way your windows instance does(I'm assuming you are using an Internet Gateway in the VPC). A reverse proxy can be set up in IIS and configured to use the private address of the linux instance.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top