简体   繁体   English

谷歌云平台 Static 网站 SLL 问题

[英]Google Cloud Platform Static Website SLL issue

I purchased a domain via third party recently and I am trying to host my website on Google Cloud Storage, I have a few issues which I cannot find any solutions for.我最近通过第三方购买了一个域,并且我正在尝试在 Google Cloud Storage 上托管我的网站,但我遇到了一些我找不到任何解决方案的问题。

1) I bought an SSL cert via my domain provider and now am trying to attach it to my bare domain. 1)我通过我的域提供商购买了 SSL 证书,现在正试图将其附加到我的裸域。 I also have my buckets for bare domain, www domain, and a subdomain.我也有裸域、www 域和子域的存储桶。 I have added my SSL to App Engine but nothing comes out of it.我已将 SSL 添加到 App Engine 中,但没有任何结果。

Here are my buckets: Buckets这是我的水桶:水桶

Here is my DNS setting: DNS这是我的 DNS 设置: DNS

And here are my custom domains on GCP App Engine: Custom Domains这是我在 GCP App Engine 上的自定义域:自定义域

I initially had a URL re-direct to www.shivnpatel.com but then changed it to the IPV4 provided.我最初有一个 URL 重定向到 www.shivnpatel.com 但后来将其更改为提供的 IPV4。 Also, the SSL security for bare domain was my SSL cert which I bought from my domain provider.此外,裸域的 SSL 安全性是我从域提供商处购买的 SSL 证书。 I had to change that to Google managed so I could attach it a bucket as I was told by my domain provider (I had a bucket for shivnpatel.com but deleted it because nothing was being fixed...).我不得不将其更改为 Google 管理,以便我可以按照我的域提供商告诉我的那样附加一个存储桶(我有一个用于 shivnpatel.com 的存储桶,但由于没有修复任何内容而将其删除......)。

Anyway, after changing my DNS to add an A record, my site started giving me 404 errors.无论如何,在更改我的 DNS 以添加 A 记录后,我的网站开始给我 404 错误。 So how should I fix this mess?那么我该如何解决这个烂摊子呢?

2) my subdomains, www.shivnpatel.com and resume.shivnpatel.com have an error next to them (as show in the 3rd image above) saying 2)我的子域 www.shivnpatel.com 和 resume.shivnpatel.com 旁边有一个错误(如上图所示)

DNS records could not be found.找不到 DNS 记录。 Certificate activation will retry automatically.证书激活将自动重试。

How can I fix this?我怎样才能解决这个问题? How can I give my subdomains SSL?如何给我的子域 SSL?

Also, since all of this is Google managed, is adding SSL necessary?此外,由于所有这些都是 Google 管理的,是否有必要添加 SSL? And lastly, would anyone recommend using Cloudflare and providing my site using it to get out of this mess?最后,有人会推荐使用 Cloudflare 并提供我的网站使用它来摆脱这种混乱吗?

Thanks in advance!提前致谢!

Since you already have your domain, by following your approach, first you need to map your custom domain on GCP, then update your DNS records with your registrar (I believe you are missing this step, check this for more detailed information).由于您已经拥有域,按照您的方法,首先您需要在 GCP 上map 您的自定义域,然后使用您的注册商更新您的 DNS记录(我相信您缺少此步骤,请查看以获取更多详细信息)。

You can use your own certificate or use a Google Managed one in App Engine, if you still want to use your own follow this steps (in the same page you can find the instructions if you decide to use Google Managed Certificates instead, but it doesn't support Wildcard Mappings).您可以使用自己的证书或在 App Engine 中使用 Google 管理的证书,如果您仍想使用自己的,请按照以下步骤操作(如果您决定改用 Google 管理的证书,您可以在同一页面中找到说明,但它不会'不支持通配符映射)。

There are some other options if you just want to use buckets:如果您只想使用存储桶,还有其他一些选项:

  1. The simplest scenario is if you are planning to host only static websites , you can manage or add subdomains too.最简单的情况是,如果您计划仅托管 static 网站,您也可以管理或添加子域
  2. Use a Bucket as backend for a Load Balancer, but this adds complexity, it depends on your needs.使用Bucket 作为负载均衡器的后端,但这会增加复杂性,这取决于您的需求。

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

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