【发布时间】:2017-03-16 03:33:11
【问题描述】:
尝试在 Heroku 上部署我的应用时,我收到以下错误:
Cannot GET /
NOT FOUND - The server has not found anything matching the requested URI (Uniform Resource Identifier).
Server is being run outside of live development mode, meaning it will only serve the compiled application bundle in ~/dist. Generally you do not need an application server for this and can instead use a web server such as nginx to serve your static files. See the "deployment" section in the README for more information on deployment strategies.
我知道我应该“实时”运行它,而不是从本地主机,所以我通过 CLI 设置了以下设置:
heroku config:set NODE_ENV=production
heroku config:set NODE_PATH=./src
heroku config:set NPM_CONFIG_PRODUCTION=false
我还应该检查什么。该应用程序是该锅炉的克隆:https://github.com/davezuko/react-redux-starter-kit
我的 Heroku 链接是:https://hidden-temple-43853.herokuapp.com/
【问题讨论】:
标签: javascript heroku isomorphic-javascript