2

I recently bough a domain with Namecheap with the intention to point it to an AWS S3 static site. My problem is that putting 'www.tagisow.dev' and 'tagisow.dev' into the address bar leads me to an infinite "Connecting.." loop in Chrome and Firefox.

What I tried:

  • Funnily enough wayback machine sees the website: http://web.archive.org/web/20190907091529/http://www.tagisow.dev/

  • I can curl the domain just fine with curl www.tagisow.dev and it returns the contents of index.html

  • I'm wondering if the fact that the .dev TLD is HSTS - which means it absolutely requires HTTPS to function has something to do with my problem. But I remember getting a warning once inside Chrome that this domain requires HSTS. Right now I'm not getting anything, just "connecting..."

    1. I created the bucket with static website enabled and changed the policy to allow everyone to read it's contents: enter image description here enter image description here enter image description here

The endpoint is working fine: http://www.tagisow.dev.s3-website.eu-central-1.amazonaws.com

  1. Changed the Namecheap records to point to my AWS S3 static website endpoint (picture 1)

enter image description here enter image description here

I really have no idea what to do now. The DNS records are fine, S3 bucket is up - I can't think of anything else to check.

  • It works for me now. – Stephen Ostermiller Sep 7 at 17:06
  • 1
    " I'm wondering if the fact that the .dev TLD is HSTS - which means it absolutely requires HTTPS to function has something to do with my problem." Most probably not. This just signals the browser to never attempt an HTTP connection on it. Also, 1) do not use nslookup, use dig, and 2) do not use ANY as query type, it does not do what you think it does, and it is now becoming obsolete to support on nameservers – Patrick Mevzek Sep 8 at 6:08
  • The first step for DNS configuration is any online troubleshooting tool but most probably either DNSViz or Zonemaster. – Patrick Mevzek Sep 8 at 6:09
1

The website started working but I completely changed my approach.

  • I ignored the problem that I can't connect through the domain name using HTTP.
  • Decided to just start setting up HTTPS for the site instead

I followed a tutorial that explained how to set up SSL for an AWS S3 static site using:

  • Amazon Route 53
  • Amazon CloudFront
  • Amazon Certificate Manger

Based on the tutorial I posted you need to:

  1. Create an e-mail redirect for your domain in Namecheap control panel - it must be something like admin@yourdomain or webmaster@yourdomain (required for Amazon Certificate Manager)

  2. Create a ACM SSL certificate (free) for your website. Use e-mail verification - the e-mail will be sent to the e-mail redirect you set

  3. Create a CloudFront distribution that redirects HTTP to HTTPS and link it to your S3 bucket address (the long AWS link)

  4. Use Route53 to route traffic to your cloudfront distribution. Your Route 53 hosted zone will assign you 4 DNS servers - you need to manually copy them into the Namecheap domain panel (first tab in your domain's Namecheap panel)

  • 1
    The reason this solves your problem is that the site won't work in browsers that support HSTS until you have HTTPS set up. Even though you were trying to connect via http, they were automatically upgrading those requests to https and being unable to connect. Other clients such as wget and the archive.org crawler may not implement HSTS and would be willing to connect to http. – Stephen Ostermiller Oct 19 at 13:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.