How to get HTTPS working on AWS and Heroku

December 19, 2018 ▪ 0 min read Technology / Web Development

Problem: I'm using Dreamhost as my domain registrar and wanted to keep all domains there, but also host on AWS, Heroku, or similar. Hence, the issues with DNS, ALIAS, CNAME, etc.

Solution: AWS

  • Create a new hosted zone (AWS Route 53)
  • Add the provided NS to registered domain (Dreamhost)
  • Add ALIAS to EB instance and CNAME to naked domain (Route 53)
  • Issue certificate to naked domain (AWS Certificate Manager)
  • Add port listener 443 HTTPS 80 HTTP linked to issued certificate (AWS EB Load Balancer)

Solution: Heroku via Cloudflare

  • Add a new website (Cloudflare)
  • Add provided NS to registered domain (Dreamhost)
  • Add CNAME @ to *.herokuapp url (Cloudflare)
  • Add CNAME www to *.herokuapp url (Cloudflare)
  • Issue certificate (Heroku)
  • Add naked domain and www domain to domain list (Heroku)

EDIT (November 04, 2020): Cleaned up to better fit updated website format.

EDIT (December 20, 2018): HTTPS still working on both naked and www domain.