[英]how to serve a content over https
I am facing problem when I call an api end point url from a https page.当我从 https 页面调用 api 端点 url 时,我遇到了问题。 I have hosted my front-end code in aws s3 bucket and a third party ssl certificate is deployed .so my react code is served over https.我已经在 aws s3 存储桶中托管了我的前端代码,并部署了第三方 ssl 证书。所以我的反应代码是通过 https 提供的。 And my back-end is deployed inside a single instance application of elastic bean stalk.我的后端部署在弹性豆茎的单实例应用程序中。 while I am trying to call my back-end url from my front-end application, it is throwing the below error.当我试图从我的前端应用程序调用我的后端 url 时,它抛出以下错误。
Mixed Content: The page at '' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint ''.混合内容:“”处的页面已通过 HTTPS 加载,但请求了不安全的 XMLHttpRequest 端点“”。 This request has been blocked;此请求已被阻止; the content must be served over HTTPS.内容必须通过 HTTPS 提供。
Can anyone help me to resolve this issue.谁能帮我解决这个问题。 Thanks.谢谢。
You need to setup your ELB (AWS Elastic Beanstalk) application to use SSL/HTTPS您需要设置您的 ELB (AWS Elastic Beanstalk) 应用程序以使用 SSL/HTTPS
https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/configuring-https.html https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/configuring-https.html
You can set this up with Route53 and AWS Certificate Manager (ACM).您可以使用 Route53 和 AWS Certificate Manager (ACM) 进行设置。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.