- Newest
- Most votes
- Most comments
Haven't succeeded so far , About an ssl certificate : aws requires that the ssl will be with a domain . Currently i can obtain an ssl certificate domain with a validated domain, but the domain website is not on this EC2 . It's a wix website . will it make me trouble over that , can i resolve it somehow ?
Hello,
setting up and forwarding a public IP to a private IP in an EC2 Windows server for an HTTP/HTTPS listener, even without a domain.
Let's Setup:
1.Create a Network Interface:
- Open the EC2 console in your AWS account.
- Go to the "Network Interfaces" section.
- Click "Create network interface".
- Choose a VPC and subnet where you want the private IP to reside.
- Select "Enable auto-assign IP address" and choose an IP address range.
- Click "Create".
2.Attach the Network Interface to your EC2 Instance:
- Go to the "Instances" section of the EC2 console.
- Select the EC2 instance where you want to forward the public IP.
- Click "Actions" -> "Network" -> "Attach network interface".
- Choose the network interface you created in step 1 and click "Attach".
3.Configure Security Groups:
- In the EC2 console, go to the "Security groups" section.
- Edit the security group associated with the EC2 instance.
- Add inbound rules to allow HTTP (port 80) and HTTPS (port 443) traffic from the public IP address to the private IP address.
4.Configure the EC2 Instance:
- Connect to the EC2 instance using RDP or SSH.
- Install and configure a web server (e.g., IIS, Apache) on the instance.
- Configure the web server to listen on the private IP address and port.
- If you need to use HTTPS, obtain an SSL certificate for the public IP address (e.g., from AWS Certificate Manager) and configure it on the web server.
5.Create an Elastic IP (EIP):
- In the EC2 console, go to the "Elastic IPs" section.
- Click "Allocate Elastic IP".
- Choose a region and click "Allocate".
6.Associate the EIP with the Network Interface:
- Go to the "Network Interfaces" section.
- Select the network interface you created in step 1.
- Click "Actions" -> "Network" -> "Associate elastic IP address".
- Choose the EIP you allocated in step 5 and click "Associate".
- Now, you should be able to access your web server using the public IP address.
Hello,
Please try this solution.
Simplified way to forward a public IP to a private IP on your EC2 Windows Server instance for HTTP/HTTPS traffic without using a load balancer or domain.
1. Configure Security Groups
- To the EC2 instance's security group allows inbound traffic on ports 80 HTTP and 443 HTTPS.
2. Set Up Port Forwarding on Windows Server
RDP into Your EC2 Instance
- Connect to your Windows Server instance using Remote Desktop RDP.
Open Command Prompt as Administrator
- Open the Command Prompt with administrator privileges.
Set Up Port Forwarding Using "netsh"
- Forward traffic from the public IP (on port 80 and 443) to the private IP using the netsh command.
For HTTP Port 80.
netsh interface portproxy add v4tov4 listenport=80 listenaddress=0.0.0.0 connectport=80 connectaddress=Private IP
For HTTPS Port 443.
netsh interface portproxy add v4tov4 listenport=443 listenaddress=0.0.0.0 connectport=443 connectaddress=Private IP
Replace Private IP with the private IP address of your EC2 instance.
3. Test the Setup
-
Access your application using the public IP address in your web browser.
-
For HTTP: http://Public IP.
-
For HTTPS: https://Public IP.
Relevant content
- asked a year ago
- asked 2 years ago

Yes, using an SSL certificate for a domain that points to a different website can cause issues.
Redirect the Domain: If possible, redirect your domain to point to the EC2 instance where you want to serve your website.
Obtain a New Certificate: If redirecting the domain is not feasible, consider obtaining a new SSL certificate specifically for the domain associated with your EC2 instance.
Hi ServerAdmin. yes you can use ssl certificate for Domain. Request an SSL certificate in AWS Certificate Manager using DNS validation, then add the provided CNAME record to your Wix DNS settings. This won't affect your Wix website, and the certificate can be used on your EC2 instance.