简体   繁体   English

如何在没有Apache和Nginx的情况下将所有HTTP请求重定向到ELB中的HTTPS

[英]How do I redirect all HTTP requests to HTTPS in ELB without Apache and Nginx

I am running python project on AWS and inplemented SSL with it. 我在AWS上运行python项目并使用它补充了SSL。 Everything is working perfectly. 一切工作正常。

Now I want to redirect all HTTP requests to HTTPS. 现在,我想将所有HTTP请求重定向到HTTPS。 It's very easy in apache/ngix but I am not using it. 在apache / ngix中这很容易,但是我没有使用它。 I have installed the SSl using AWS ELB. 我已经使用AWS ELB安装了SSl。 So I need solution for above issue. 因此,我需要上述问题的解决方案。

Thanks in advance 提前致谢

I personally use AWS CloudFront for redirecting HTTP requests to HTTPS. 我个人使用AWS CloudFront将HTTP请求重定向到HTTPS。 It's not expensive and compliments ELB nicely, and brings other benefits too. 它并不昂贵,并且很好地补充了ELB,并且还带来了其他好处。

I wrote an answer to a similar question explaining how to set it up here . 我写了一个类似问题的答案,解释了如何在这里设置它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM