HTTPS 不起作用(在基于 AWS Elastic Beanstalk 的站点上) [英] HTTPS not working (on AWS Elastic Beanstalk based site)

查看:26
本文介绍了HTTPS 不起作用(在基于 AWS Elastic Beanstalk 的站点上)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

该站点在 HTTP 上运行良好,但在 HTTPS 上不起作用.我已按照此页面上的所有步骤创建自签名证书并将其添加到我的 Elastic Beanstalk 环境中.http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/configuring-https.html

The site works perfectly fine on HTTP, however, does not work on HTTPS. I've followed all the steps on this page to create a self-signed certificate and add it to my Elastic Beanstalk environment. http://docs.aws.amazon.com/elasticbeanstalk/latest/dg/configuring-https.html

我还使用以下命令从 IAM 收到了成功的证书响应:aws iam get-server-certificate --server-certificate-name

I'm also getting a successful certificate response back from IAM using the following command: aws iam get-server-certificate --server-certificate-name

在使用证书更新 Elastic Beanstalk 后,我还向安全组添加了一条规则,允许从 0.0.0.0/0 到端口 443 的入站流量.最后,我还验证了我的负载平衡器侦听器是否正确设置了 HTTPS.

After updating Elastic Beanstalk with the certificate, I've also added add a rule to the security group that allows inbound traffic from 0.0.0.0/0 to port 443. Finally, I've also validated that my load-balancer listener has HTTPS set up correctly.

尽管如此,我对 https 的调用仍未解决,而 http 工作正常.对此还有其他想法吗?任何帮助将不胜感激.

In spite of all that, my calls to https is not resolving, while http is working perfectly fine. Any other thoughts on this? Any help would be much appreciated.

如果您需要更多信息,请告诉我.拼命寻找对此的一些见解/帮助.

Please let me know if you need any more information. Desperately looking for some insight/help into this.

无论如何,无法通过我的站点/代码解决此问题,我尝试在 Elastic Beanstalk 上提供的示例站点上设置 HTTPS.有趣的是,即使这样也行不通.

Anyway, not being able to resolve this issue with my site/code, I tried to set up HTTPS on the sample site provided on Elastic Beanstalk. Interestingly enough, even that is not working.

推荐答案

我想提供一个我终于能够解决问题的更新.根本原因是我没有为负载均衡器的安全组设置入站规则.

I want to provide an update that I was finally able to resolve the issue. The root-cause was because I missed to set up an Inbound Rule for the Security Group of the Load Balancer.

无论出于何种原因,当我阅读文档时,我明白需要为实例的安全组(而不是负载均衡器)设置入站规则.直到我开始跟踪负载均衡器后,我才意识到我或许应该尝试为负载均衡器的安全组设置规则.这样,问题就解决了.以下是我使用的设置.

For whatever reason, when I read the documentation, I understood that the Inbound Rule needed to be set up for the Security Group of the Instance (and not the Load Balancer). Only after I started tracing the Load Balancer did I realize that I should perhaps try setting up the Rule for the Security Group of the Load Balancer. So, the problem is resolved. Below is the setting I used.

HTTPS           443     HTTP        80      <name of the certificate>

我不得不说,文档可能会更清楚一些,以清楚地确定负载均衡器(而不是实例)的安全组所需的更改.

I'd have to say that the documentation could be a bit more clear to clearly identify the change required to the Security Group of the Load Balancer (and not the Instance).

这篇关于HTTPS 不起作用(在基于 AWS Elastic Beanstalk 的站点上)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆