How to enforce HTTPS traffic to Google App Engine with custom domain?

前端 未结 4 983
说谎
说谎 2020-12-18 00:29

I have a site on Google Domains (www.example.com) and it\'s hosted with Gcloud. I followed the instructions listed here to set up SSL and https: https://cloud.google.com/app

4条回答
  •  一生所求
    2020-12-18 01:00

    secure: always still works in all standard environments, but the secure option has been deprecated in all flexible environments, see documentation here or here for Node.js.

    If you need this feature in your current environment, the suggested solutions require changes to your application code. Either use the custom HTTP header X-Forwarded-Proto to redirect the HTTP traffic to HTTPS, or use the HTTP Strict Transport Security response header.

提交回复
热议问题