我通過github
部署了應用程序,並且一切正常。但是當我打開顯示的網站:Heroku - NodeJS應用程序錯誤
應用程序錯誤
在應用程序中出現錯誤,你的頁面無法送達。請稍後重試。
If you are the application owner, check your logs for details.
我heroku
日誌:
2016-04-22T10:26:03.321608+00:00 heroku[slug-compiler]: Slug compilation finished
2016-04-22T10:26:03.321598+00:00 heroku[slug-compiler]: Slug compilation started
2016-04-22T10:26:04.121512+00:00 heroku[web.1]: State changed from crashed to starting
2016-04-22T10:26:13.903416+00:00 heroku[web.1]: Starting process with command `npm start`
2016-04-22T10:26:16.220624+00:00 app[web.1]:
2016-04-22T10:26:16.220639+00:00 app[web.1]: > [email protected] start /app
2016-04-22T10:26:16.220641+00:00 app[web.1]: > node server/index
2016-04-22T10:26:16.220642+00:00 app[web.1]:
2016-04-22T10:26:16.646330+00:00 app[web.1]: fs.js:549
2016-04-22T10:26:16.646366+00:00 app[web.1]: return binding.open(pathModule._makeLong(path), stringToFlags(flags), mode);
2016-04-22T10:26:16.646390+00:00 app[web.1]: ^
2016-04-22T10:26:16.646392+00:00 app[web.1]:
2016-04-22T10:26:16.646392+00:00 app[web.1]: Error: ENOENT: no such file or directory, open '/app/config/build-config.json'
2016-04-22T10:26:16.646393+00:00 app[web.1]: at Error (native)
2016-04-22T10:26:16.646394+00:00 app[web.1]: at Object.fs.openSync (fs.js:549:18)
2016-04-22T10:26:16.646394+00:00 app[web.1]: at Object.fs.readFileSync (fs.js:397:15)
2016-04-22T10:26:16.646395+00:00 app[web.1]: at Object.<anonymous> (/app/config/config.js:9:30)
2016-04-22T10:26:16.646395+00:00 app[web.1]: at Module._compile (module.js:409:26)
2016-04-22T10:26:16.646396+00:00 app[web.1]: at Object.Module._extensions..js (module.js:416:10)
2016-04-22T10:26:16.646396+00:00 app[web.1]: at Module.load (module.js:343:32)
2016-04-22T10:26:16.646397+00:00 app[web.1]: at Function.Module._load (module.js:300:12)
2016-04-22T10:26:16.646397+00:00 app[web.1]: at Module.require (module.js:353:17)
2016-04-22T10:26:16.646399+00:00 app[web.1]: at require (internal/module.js:12:17)
2016-04-22T10:26:16.654518+00:00 app[web.1]:
我知道一個文件丟失。但是它在哪個文件中調用缺少的文件?
新錯誤。這次發生了什麼?
我的猜測是「/app/config/build-config.json」在失蹤引發錯誤同一時間文件路徑一些你指定的地方沒有被程序識別 – Prasad
你有沒有找到一種方法,爲什麼它總是看着文件夾下的應用程序文件夾是我們更改默認文件夾或找到任何解決方案?感謝yoıu – dewelloper