gpt4 book ai didi

azure - azure 上的 keystone 部署失败

转载 作者:行者123 更新时间:2023-12-03 04:25:05 25 4
gpt4 key购买 nike

我有一个 azure web 应用程序,并将我的 keystone 应用程序从 github 部署到 azure。不幸的是我最终遇到了 500 错误:

Tue May 23 2017 19:36:05 GMT+0000 (Coordinated Universal Time): Application has thrown an uncaught exception and is terminated:
Error: ENOENT: no such file or directory, scandir 'D:\home\site\wwwroot\C:\DWASFiles\Sites\chronasWebApp\DynamicCache\wwwroot\routes\api'
at Error (native)
at Object.fs.readdirSync (fs.js:945:18)
at importer (C:\DWASFiles\Sites\chronasWebApp\DynamicCache\wwwroot\node_modules\keystone\lib\core\importer.js:32:6)
at Object.<anonymous> (C:\DWASFiles\Sites\chronasWebApp\DynamicCache\wwwroot\routes\index.js:37:7)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)
at Function.Module._load (module.js:409:3)
at Module.require (module.js:468:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (C:\DWASFiles\Sites\chronasWebApp\DynamicCache\wwwroot\keystone.js:59:24)
at Module._compile (module.js:541:32)
at Object.Module._extensions..js (module.js:550:10)
at Module.load (module.js:458:32)
at tryModuleLoad (module.js:417:12)

如何知道问题是什么?这是我们部署的应用程序: https://github.com/aumanjoa/chronas-community

package.json:
{
"name": "chronas",
"version": "2.0.0",
"private": true,
"repository": {
"type": "git",
"url": "https://github.com/daumann/chronas-community.git"
},
"dependencies": {
"async": "^2.4.1",
"babel-core": "^6.24.1",
"babel-plugin-syntax-object-rest-spread": "^6.13.0",
"babel-plugin-transform-object-rest-spread": "^6.23.0",
"babel-preset-es2015": "^6.24.1",
"babel-preset-react": "^6.24.1",
"babel-register": "^6.24.1",
"babelify": "^7.3.0",
"body-parser": "^1.17.2",
"browserify-middleware": "^7.1.0",
"classnames": "^2.2.5",
"connect-mongo": "^1.3.2",
"crypto": "0.0.3",
"dotenv": "^4.0.0",
"express-graphql": "^0.6.5",
"graphql": "^0.9.6",
"graphql-relay": "^0.5.1",
"gulp": "^3.9.1",
"gulp-zip": "^4.0.0",
"jade": "^1.11.0",
"keystone": "https://github.com/keystonejs/keystone.git#f3083c",
"lodash": "^4.17.4",
"log4js": "^1.1.1",
"moment": "^2.18.1",
"newrelic": "^1.39.1",
"passport": "^0.3.2",
"passport-facebook": "^2.1.1",
"passport-github": "^1.1.0",
"passport-google-oauth": "^1.0.0",
"passport-twitter": "^1.0.4",
"react": "^15.5.4",
"react-dom": "^15.5.4",
"request": "^2.81.0",
"store-prototype": "^1.1.1",
"superagent": "^3.5.2",
"underscore": "^1.8.3"
},
"engines": {
"node": "6.2.2",
"npm": "3.9.5"
},
"scripts": {
"start": "node keystone.js",
"print-graphql-schema": "babel-node ./graphql/scripts/printSchema.js"
}
}

最佳答案

问题与此错误相关 Azure and node js __dirname

通过更新到新的节点版本修复了该问题。

"node": "6.10.0",
"npm": "3.10.10"

关于azure - azure 上的 keystone 部署失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/44143664/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com