403 尝试 运行 简单静态时禁止 nginx html

403 Forbidden nginx when trying to run simple static html

我正尝试在 bluemix 服务器上 运行 一个简单的 html 页面。但是我收到 403 Forbidden 错误。我正在使用 manifest.yml 进行部署。 这是 manifest.yml 包含的内容:

---
applications:
- buildpack: https://github.com/cloudfoundry/staticfile-buildpack.git
  host: helloworld-html-${random-word}
  name: lab6
  memory: 64M
  stack: cflinuxfs2

我不知道该怎么做才能解决这个问题。这就是文件结构的样子。另外,为什么我的 Javascript 显示错误 'document' is undefined。它在 bluemix 之外工作正常(例如在浏览器中)。

对于遇到此问题的任何人,您要显示的 html 文件的名称必须是 index.html。完成后它会起作用。您还必须在根目录中。