Route 53 Alias To API Gateway Not Routing Traffic

0

Hi everyone,

I recently followed multiple tutorials from both AWS and Youtube to make sure I set up everything correctly. To summarize - I've set up a custom domain name for an api in API Gateway, and I've also configured some Cloudwatch Logs so I know when a request hits the Api. My Route53 has the correct record (using A-Alias type) to route api.mywebsite.com to the API Gateway domain name as seen in the API Gateway console. However, when I try to see if api.mywebsite.com resolves correctly, it does not. In addition, it does not log anything to Cloudwatch, suggesting that it's not even routing traffic.

Things I've tried -

  1. adding different routes to the API Gateway configuration.
  2. modifying the custom domain name mapping to have an empty path so that api.mywebsite.com by itself is accepted by API Gateway, theoretically.
  3. changing the ACM certificate used by the custom domain to match the name of api.mywebsite.com, character for character.
  4. adding a $default route in API Gateway that will accept any path.

I feel like I'm reaching the end of my rope here. I apologize in advance if these forums are not the best place for such questions.

asked 4 years ago949 views
2 Answers
1

I feel very silly - it turns out that in my computer browser typing in api.mywebsite.com directed to http://api.mywebsite.com, which failed, as compared to my mobile browser, which directed it to https://api.mywebsite.com, which worked.

Closing this thread

answered 4 years ago
0

Another interesting thing is that my mobile browser successfully hits the backend through api.mywebsite.com, but on my desktop Chrome and Firefox hitting api.mywebsite.com fails.

answered 4 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.

Guidelines for Answering Questions