Search code examples
amazon-web-servicesamazon-ec2amazon-elastic-beanstalk

ERR_CONNECTION_REFUSED when routing AWS Elastic Beanstalk environment to custom domain


My ELB instance works fine on the dedicated elasticbeanstalk.com subdomain, however when I route it to my custom domain https://hoodie.dev, it returns ERR_CONNECTION_REFUSED.

Before adding an HTTPS rule to my inbound rules, it returned ERR_CONNECTION_TIMED_OUT

I have already tried changing the security groups, currently I am allowing:

  • HTTPS from 0.0.0.0
  • HTTP from 0.0.0.0
  • SSH from 0.0.0.0

I'm relatively new to using AWS and web development, so I would appreciate if your answers are detailed.


Solution

  • Nevermind, I figured this out thanks to the help of @Mark B

    I had to configure my elastic beanstalk instance and changed it from single environment to load balanced. A video that helped me with this this:

    https://www.youtube.com/watch?v=pBOcPxho_wg