在Heroku上启用https
我有一个在Heroku上运行的应用程序,带有一个简单的API的Node.js后端和一个React.js前端。 请求代理到后端( http://localhost:5000
)。
当我从React ping API时,出现以下错误:
Mixed Content: The page at 'https://**.herokuapp.com/users' was loaded over HTTPS, but requested an insecure resource 'http://localhost:5000/api/users'. This request has been blocked; the content must be served over HTTPS.
我怎样才能使资源安全?