繁体   English   中英

为什么 firebase 自定义域不返回 index.html?

[英]Why firebase custom domain don't return index.html?

我在 firebase 有一个项目,有两个自定义域,如图firebase 控制台所示。

第一个colademonofrozen.cl/我得到 index.html 文件 OK,但是第二个www.colademonofrozen.cl/我得到 404 not found。

这个案例有些奇怪的是www.colademonofrozen.cl/anything显示 index.html 文件 OK。

这是托管配置:`

  "hosting": {
    "public": "dist",
    "ignore": [
      "firebase.json",
      "**/.*",
      "**/node_modules/**"
    ],
    "rewrites": [
      {
        "source": "/api/**",
        "function": "app",
        "region": "us-central1" 
      },
      {
        "source": "/admin",
        "destination": "/admin.html"
      },
      {
        "source": "**",
        "destination": "/index.html"
      }
    ]
  },

`

我为这个项目做了很多工作,我真的很感激任何想法。

我也感谢任何确认该域显示错误页面的人,因此如果它开始工作则不能忽略该问题。

  • 我确认这不是缓存问题。
  • 子域是两周前配置的,不是时间传播问题。
  • 我在我的 dns 提供商处请求重定向,从子域www.colademonofrozen.cl/colademonofrozen.cl/ ,但如果域指向 Firebase 则不可能。

不幸的是,我为其创建项目的产品的背面 label 已经打印出来了。 看背面标签!

我更改以下 DNS 记录:

姓名 类型 价值
www.colademonofrozen.cl。 别名 colademonofrozen.cl

为了:

姓名 类型 价值
www.colademonofrozen.cl。 一种 199.36.158.100

现在工作正常。

暂无
暂无

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

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