Skip to content

Re-route Route 53 zone (domain) to EC2 website (different domain) but maintain existing Workmail for original domain

0

I want to forward all A.com website activity (in Route 53) to B.com website (under EC2 - different IP, same zone) but want all A.com email to continue to the original Workmail site setup on Route 53. I cannot simply change the A DNS record. This eliminates access to the email account. I have considered possibly using an Alias A record for this, but I am uncertain if this will work. A.com domain is through a separate domain server but uses 4 AWS DNS servers. Any thoughts are appreciated.

5 Answers
5

Hello,

To forward all web traffic from A.com to B.com while keeping A.com’s email functioning through WorkMail, follow these steps:

Create an Alias Record: In Route 53, create an Alias A record at the apex of A.com that points to the EC2 instance or Load Balancer of B.com.

Maintain MX Records: Ensure that the MX records for A.com in Route 53 remain unchanged to continue directing email to WorkMail.

This setup allows web traffic to be routed to B.com while keeping email services intact for A.com.

EXPERT
answered 2 years ago
EXPERT
reviewed 2 years ago
  • Good thought. Tried it. AWS would not let me create an A alias apex record that points to an ec2 instance.

3

=>To redirect A.com to B.com while maintaining email functionality for A.com:

=>Create an S3 bucket named A.com and configure it for website redirection to B.com.

=>In Route 53, set an Alias A record for A.com pointing to the S3 bucket.

=>Keep the existing MX records for A.com in Route 53 to ensure emails continue to route to Workmail.

=>This setup redirects web traffic from A.com to B.com without disrupting email services for A.com.

EXPERT
answered 2 years ago
EXPERT
reviewed 2 years ago
EXPERT
reviewed 2 years ago
EXPERT
reviewed 2 years ago
0

Good thought. Tried it. Response was: (InvalidChangeBatch 400: RRSet of type CNAME with DNS name A.com is not permitted at apex in zone A.com.). Perhaps I am setting up the CNAME record incorrectly, though it seems fairly straight forward.

answered 2 years ago
0

You can create a CNAME record in the A.com zone which directs A.com to B.com.

Email for A.com is directed by MX records in the A.com zone.

Hope this helps.

AWS
EXPERT
answered 2 years ago
EXPERT
reviewed 2 years ago
EXPERT
reviewed 2 years ago
0

There were some great suggestions but nothing seemed to work. Part of the problem is redirecting was to a SSL (HTTPS) b.com website. Since it was not clear what the web server was and where the approriate configure file was (two totally different sites are being served from the same IP address), I gave up and modfide an a.com index.html file to the following:

<!DOCTYPE HTML> <html> <head> <meta http-equiv="refresh" content="0;url=http://b.com" /> </head> <body> </body> This was less then ideal, but it works.
answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.