https:// to https://www does not work

0

I created a distribution and in DNS section created A record pointing @klionsky.org to my Destribution

so, https://klionsky.org and http://klionsky.org do work.
However, https://WWW.klionsky.org does not work.
403 ERROR
The request could not be satisfied.
I tried to add CNAME record for www.klionsky.org to resolve to klionsky.org but that did not help.
How can I fix this?
thank you!

Edited by: DanielAT2021 on Jul 14, 2021 11:42 PM

Edited by: DanielAT2021 on Jul 14, 2021 11:43 PM

質問済み 3年前203ビュー
9回答
0

Check your cname...

$ host www.klionsky.org
Host www.klionsky.org not found: 3(NXDOMAIN)

Also, your klionsky.org dns entry is pointing directly to cloudfront / distribution IP addresses. You should use CNAME's for host entries that are using distributions. That way the AWS infrastructure can find the best node to serve the content.

profile picture
David G
回答済み 3年前
0

David,
I probably don't understand your answer.

(A) record has my bare domain name, klionsky.org, that points to the name of my cloudfront / distribution. Is that correct or not?
+
I added CNAME www.klionsky.org pointing to my distribution... However, I'm still getting an error when trying to access www.klionsky.org.

I'm following this article
https://lightsail.aws.amazon.com/ls/docs/en_us/articles/amazon-lightsail-point-domain-to-distribution:

Complete one of the following steps depending on the type of domain that you want to point to your distribution:
Choose an address (A) record to point an apex domain (e.g., example.com) to your distribution.
If an A record for the apex of your domain is already present in your DNS zone, then you will need to edit that existing record instead of adding another A record.
Choose a canonical name (CNAME) to point a sub domain (e.g., website.example.com) to your distribution.

回答済み 3年前
0

I found a problem with my setup:
In my certificate I have had only my bare domain name, klionsky.org. Once I added www.klionsky.org it started to work.
I have had to delete the old certificate and create a new one with both klionsky.org & www.klionsky.org.

回答済み 3年前
0

Could you instead use A entries for the www and non-www versions of the domain and point them to the Cloudfront default domain (eg sjn12b18snb1.cloudfront.net). Please see here: https://i.imgur.com/OFVGKCv.png

I do this and the CDN seems to function correctly.

回答済み 3年前
0

noobnoob wrote:
Could you instead use A entries for the www and non-www versions of the domain and point them to the Cloudfront default domain (eg sjn12b18snb1.cloudfront.net). Please see here: https://i.imgur.com/OFVGKCv.png

Is that route53?

"A" records point to a specific IP address.

"CNAME" records are alias's that point to other records ("A" or "CNAME").

You should always create a CNAME to point to a Lightsail distribution. That way the AWS Cloudfront infrastructure can find the best end point to connect the request to.

profile picture
David G
回答済み 3年前
0

Hi yes it is Route 53.

In the screenshot you can see it is an A record but the option selected is "Alias to Cloudfront distribution", so it is not pointing to a specific IP address.

Therefore I guess the infrastructure is working as intended?

Edited by: noobnoob on Jul 21, 2021 2:11 PM

回答済み 3年前
0

True, it works.
However, the terminology is wrong and will probably lead to confusion and misunderstanding when interacting with people who use the more common terms.

profile picture
David G
回答済み 3年前
0

Yes I only worked it out after some playing around.

回答済み 3年前
0

Yes I only worked it out after some playing around.

回答済み 3年前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ