【问题标题】:Google Cloud Storage Bucket: XML error when reloading an Ember.js app in GCSGoogle Cloud Storage Bucket:在 GCS 中重新加载 Ember.js 应用时出现 XML 错误
【发布时间】:2017-04-08 17:38:40
【问题描述】:

我们最近将托管在 Amazon AWS S3 存储桶中的 Ember.js 应用程序移至 Google Cloud Storage 存储桶。当我们加载 index.html 页面时,该应用程序运行良好。 Ember 过渡效果很好,但是,当我们直接访问不是项目主路由的 URL(例如,/account-settings)或重新加载我们正在处理的 URL 时,我们会收到以下错误:

<Error>
    <Code>NoSuchKey</Code>
    <Message>The specified key does not exist.</Message>
</Error>

我的假设是这与 Ember 路由器和 index.html 未处理的请求有关?有没有办法告诉谷歌云存储将所有请求重定向到 index.html 以便 Ember 路由器可以处理它?我在 Google Cloud 文档中找不到解决此问题的任何解决方案。我该如何解决这个问题?

【问题讨论】:

    标签: javascript ember.js google-cloud-storage google-cloud-platform


    【解决方案1】:

    我设法通过将我的 Google Cloud Storage 存储桶的错误页面设置为 index.html 来解决此问题。

    【讨论】:

      猜你喜欢
      • 2019-03-31
      • 2017-07-12
      • 1970-01-01
      • 2017-11-08
      • 2021-01-09
      • 2020-03-24
      • 1970-01-01
      • 1970-01-01
      • 2013-07-01
      相关资源
      最近更新 更多