Skip to content

Amazon Q Web Experience URL Alias Redirect to custom Domain

0

As an AWS Architect aiming to direct users to a new Amazon Q web experience via a custom domain name managed by Route 53, I've encountered challenges despite creating public hosted zones in both us-east-2 and us-west-1 regions, where the service is active. Despite trying various alias and record types, Amazon Q does not appear in the service list for alias targets. Resorting to a standard CNAME record introduces certificate issues and results in a 'host not found' error. Given these circumstances, what are the recommended steps or configurations to successfully map a custom domain to the Amazon Q web experience, ensuring secure and error-free redirection?"

I have already investigated the following article. https://repost.aws/knowledge-center/route-53-no-targets, but unfortunately this didn't help.

5 Answers
0
Accepted Answer

Hi THere

You can use CloudFront in front of your Amazon Q for Business URL.

  1. Create an SSL Certificate for your custom domain name in AWS Certificate Manager. Complete all validation steps
  2. Create a CloudFront Distribution and point it to the Amazon Q for Business hostname
  3. Point the CloudFront distribution to your ACM certificate, and add your custom domian name as an Alternate Domain Name
  4. Once your CloudFront distribution is deployed, create an Alias record in Route53 pointing to your CloudFront distribution

I just tested this and it works fine. Once you are logged into Q, the Amazon Q URL is displayed in the broser, but the redirection from your custom domain to your iDp and back to Q works ( I tested with Azure AD)

AWS
EXPERT

answered 2 years ago

0

Many thanks. I followed the above solution with success.

answered 2 years ago

0

Hi Matt-B. I'm having a heck of a time getting this to work. I followed your instructions and keep getting {"message":"Invalid host"}. This happens when trying to use the custom domain name as well as the Cloudfront URL.

The ACM is set up and I don't receive any certificate errors. When I do an nslookup for the custom domain, it resolves properly to the Cloudfront IPs. I tried appending /#/chat in the URL but it doesn't change anything.

What's interesting is if I try something like /chat or /blah, it returns with a 404 Not Found Amazon Q Powered by Amazon Web Services error page, so it's clearly reaching Q.

We use OKTA. Am I supposed to somehow redirect to companydomain.okta.com somehow? Any help would be greatly appreciated. Thanks

Cloudfront Distribution Domain Name: xxxxxxxxxx.cloudfront.net Alternate domain names: qchat.customdomain.com Origins: xxxxxxxx.chat.qbusiness.us-east-1.on.aws

Origins Origin name: qchat.customdomain.com Origin domain: xxxxxxxx.chat.qbusiness.us-east-1.on.aws

Behaviors Precedence - 0 Path pattern - Default (*) Origin or origin group - qchat.customdomain.com Viewer protocol policy - HTTP and HTTPS Cache policy name - UseOriginCacheControlHeaders Origin request policy name - Managed-AllViewer

Route53 qchat.customdomain.com - A Alias Record - xxxxxxxxxx.cloudfront.net

answered 2 years ago

0

Figured it out. I needed to change

Cache policy name: UseOriginCacheControlHeaders ---> Managed-CachingDisabled Origin request policy name: Managed-AllViewer ---> Managed-CORS-CustomOrigin

answered 2 years ago

0

Given the fact that it is an ALIAS, not a CNAME I think it won't work, but I'll shoot anyway: My customer doesn't use Route53, can I still make it work?

AWS

answered a year 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.