Reputation: 5914
I am trying to debug a situation with my elastic beanstalk enviornment where my certificate from certificate manager is successfully being recognized by my eb environment name and throwing an error, as it should, since my certificate is for my domain and not elasticbeanstalk.com, but when I try to access my site at beta.mysite.com
I notice that it is still using http and not https. As a result I am trying to determine if this is an issue with my CNAME records, my expressjs setup or something with my load balancer. Here is my current setup:
SSL ID: .*mysite.com
Load Balancer:
SSL certificate ID: .*mysite.com
Rest of options set by default
CNAME:
ExpressJS:
Upvotes: 0
Views: 141
Reputation: 200562
but when I try to access my site at beta.mysite.com I notice that it is still using http and not https.
That's simply because you went to http://beta.mysite.com instead of https://beta.mysite.com Notice how you can go to both http://stackoverflow.com and https://stackoverflow.com, that's how your application is configured right now.
Installing an SSL certificate doesn't automatically cause HTTP requests on port 80 to be redirected to HTTPS requests on port 443. You would need to add some configuration options in your Elastic Beanstalk's Nginx server, or in your ExpressJS server code, to detect requests that are HTTP, and redirect them to HTTPS, like this.
Upvotes: 1