2016-09-29 188 views
0

我设置了内Azure中的Node.js服务器喜欢这里描述:https://azure.microsoft.com/en-gb/documentation/articles/app-service-web-nodejs-get-started/天青 - Node.js的部署失败:没有这样的文件package.tgz

它的工作以及本地和@azure,我没有部署一个月到天蓝色,只在本地开发。

现在,我再次想我的应用程序集成到蔚蓝的,但全成之后使用PowerShell commiting:

git add . 
git commit -m "some fixes" 
git push azure master 

我得到:错误提取d:\本地\ AppData的\ NPM-缓存\ FS \ 0.0.0 \ package.tgz档案:ENOENT:没有这样的文件或目录

Counting objects: 2, done. 
Delta compression using up to 8 threads. 
Compressing objects: 100% (2/2), done. 
Writing objects: 100% (2/2), 242 bytes | 0 bytes/s, done. 
Total 2 (delta 1), reused 0 (delta 0) 
remote: Updating branch 'master'. 
remote: Updating submodules. 
remote: Preparing deployment for commit id '7ddb279f93'. 
remote: Generating deployment script. 
remote: Running deployment command... 
remote: Handling node.js deployment. 
remote: KuduSync.NET from: 'D:\home\site\repository' to: 'D:\home\site\wwwroot' 
remote: Deleting file: 'iisnode.yml' 
remote: Copying file: '_iisnode.yml' 
remote: Looking for app.js/server.js under site root. 
remote: Using start-up script server.js 
remote: Generated web.config. 
remote: Node.js versions available on the platform are: 0.6.20, 0.8.2, 0.8.19, 0.8.26, 0.8.27, 0.8.28, 0.10.5, 0.10.18, 
0.10.21, 0.10.24, 0.10.26, 0.10.28, 0.10.29, 0.10.31, 0.10.32, 0.10.40, 0.12.0, 0.12.2, 0.12.3, 0.12.6, 4.0.0, 4.1.0, 4. 
1.2, 4.2.1, 4.2.2, 4.2.3, 4.2.4, 4.3.0, 4.3.2, 4.4.0, 4.4.1, 4.4.6, 4.4.7, 4.5.0, 5.0.0, 5.1.1, 5.3.0, 5.4.0, 5.5.0, 5.6 
.0, 5.7.0, 5.7.1, 5.8.0, 5.9.1, 6.0.0, 6.1.0, 6.2.2, 6.3.0, 6.5.0, 6.6.0. 
remote: Selected node.js version 4.2.3. Use package.json file to choose a different version. 
remote: Selected npm version 3.5.1 
remote: Updating iisnode.yml at D:\home\site\wwwroot\iisnode.yml 
remote: npm WARN deprecated [email protected]: Jade has been renamed to pug, please install the latest version of pug instead 
of jade 
remote: npm ERR! Windows_NT 6.2.9200 
remote: npm ERR! argv "D:\\Program Files (x86)\\nodejs\\4.2.3\\node.exe" "D:\\Program Files (x86)\\npm\\3.5.1\\node_modu 
les\\npm\\bin\\npm-cli.js" "install" "--production" 
remote: npm ERR! node v4.2.3 
remote: npm ERR! npm v3.5.1 
remote: npm ERR! code EREADFILE 
remote: 
remote: npm ERR! Error extracting D:\local\AppData\npm-cache\fs\0.0.0\package.tgz archive: ENOENT: no such file or direc 
tory, open 'D:\local\AppData\npm-cache\fs\0.0.0\package.tgz' 
remote: npm ERR! 
remote: Failed exitCode=1, command="D:\Program Files (x86)\nodejs\4.2.3\node.exe" "D:\Program Files (x86)\npm\3.5.1\node 
_modules\npm\bin\npm-cli.js" install --production 
remote: npm ERR! If you need help, you may report this error at: 
remote: An error has occurred during web site deployment. 
remote: npm ERR!  <https://github.com/npm/npm/issues> 
remote: 
remote: npm ERR! Please include the following file with any support request: 
remote: npm ERR!  D:\home\site\wwwroot\npm-debug.log 
remote: 
remote: Error - Changes committed to remote repository but deployment to website failed. 
To https://[email protected]/xxxxxxrver.git 
    1a34e23..7ddb279 master -> master 
PS D:\DEV\_Thesis\Thesis_RenegadeService\Node Renegade Server> git add . 
warning: LF will be replaced by CRLF in iisnode.yml. 
The file will have its original line endings in your working directory. 
PS D:\DEV\_Thesis\Thesis_xxxxxxrvice\Node xxxxxade Server> git commit -m "fixing" 
[master 5a8a254] fixing 
warning: LF will be replaced by CRLF in iisnode.yml. 
The file will have its original line endings in your working directory. 
1 file changed, 0 insertions(+), 0 deletions(-) 
rename _iisnode.yml => iisnode.yml (100%) 
PS D:\DEV\_Thesis\Thesis_xxxxxervice\Node xxxxade Server> git push azure master 
Counting objects: 2, done. 
Delta compression using up to 8 threads. 
Compressing objects: 100% (2/2), done. 
Writing objects: 100% (2/2), 233 bytes | 0 bytes/s, done. 
Total 2 (delta 1), reused 0 (delta 0) 
remote: Updating branch 'master'. 
remote: Updating submodules. 
remote: Preparing deployment for commit id '5a8a2543a4'. 
remote: Generating deployment script. 
remote: Running deployment command... 
remote: Handling node.js deployment. 
remote: KuduSync.NET from: 'D:\home\site\repository' to: 'D:\home\site\wwwroot' 
remote: Copying file: 'iisnode.yml' 
remote: Looking for app.js/server.js under site root. 
remote: Using start-up script server.js 
remote: Generated web.config. 
remote: Node.js versions available on the platform are: 0.6.20, 0.8.2, 0.8.19, 0.8.26, 0.8.27, 0.8.28, 0.10.5, 0.10.18, 
0.10.21, 0.10.24, 0.10.26, 0.10.28, 0.10.29, 0.10.31, 0.10.32, 0.10.40, 0.12.0, 0.12.2, 0.12.3, 0.12.6, 4.0.0, 4.1.0, 4. 
1.2, 4.2.1, 4.2.2, 4.2.3, 4.2.4, 4.3.0, 4.3.2, 4.4.0, 4.4.1, 4.4.6, 4.4.7, 4.5.0, 5.0.0, 5.1.1, 5.3.0, 5.4.0, 5.5.0, 5.6 
.0, 5.7.0, 5.7.1, 5.8.0, 5.9.1, 6.0.0, 6.1.0, 6.2.2, 6.3.0, 6.5.0, 6.6.0. 
remote: Selected node.js version 4.2.3. Use package.json file to choose a different version. 
remote: Selected npm version 3.5.1 
remote: Updating iisnode.yml at D:\home\site\wwwroot\iisnode.yml 
remote: npm WARN deprecated [email protected]: Jade has been renamed to pug, please install the latest version of pug instead 
of jade 
remote: npm ERR! Windows_NT 6.2.9200 
remote: npm ERR! argv "D:\\Program Files (x86)\\nodejs\\4.2.3\\node.exe" "D:\\Program Files (x86)\\npm\\3.5.1\\node_modu 
les\\npm\\bin\\npm-cli.js" "install" "--production" 
remote: npm ERR! node v4.2.3 
remote: npm ERR! npm v3.5.1 
remote: npm ERR! code EREADFILE 
remote: 
remote: npm ERR! Error extracting D:\local\AppData\npm-cache\fs\0.0.0\package.tgz archive: ENOENT: no such file or direc 
tory, open 'D:\local\AppData\npm-cache\fs\0.0.0\package.tgz' 
remote: npm ERR! 
remote: Failed exitCode=1, command="D:\Program Files (x86)\nodejs\4.2.3\node.exe" "D:\Program Files (x86)\npm\3.5.1\node 
_modules\npm\bin\npm-cli.js" install --production 
remote: npm ERR! If you need help, you may report this error at: 
remote: An error has occurred during web site deployment. 
remote: npm ERR!  <https://github.com/npm/npm/issues> 
remote: 
remote: npm ERR! Please include the following file with any support request: 
remote: npm ERR!  D:\home\site\wwwroot\npm-debug.log 
remote: 
remote: Error - Changes committed to remote repository but deployment to website failed. 

它本地工作我的机器... 上自从我加入

最后部署
"passport": "*", 
"fs": "*", 
"passport-azure-ad": "*", 
"cookie-parser": "*", 
"express-session": "*", 
"jade": "*", 
"adal-node":"*" 

和一些代码使用它。

Azure Portal说,一切顺利,但部署命令。该错误包含上述打印。

创建具有相同代码的新网站抛出同样的错误..

编辑: 我在Azure目录d内浏览:\本地\ AppData的\ NPM-缓存\ FS并没有0.0。 0目录,只有0.0.2 ...我怎么告诉天青现在使用0.0.2目录..

EDIT2 我设置的“FS”的版本修复了这个问题(临时)回到包装0.0.0。现在我不能够使用更高版本的...

+1

为了确认,'fs'模块是节点核心模块的一部分,为什么需要通过npm另外安装它? –

回答

0

正如评论中的“Gary Liu - MSFT”所建议的。从包中删除fs已经成功了。

0

试图迫使你的package.json节点版本:

“引擎”:{ “节点”:“6.6.0” }

相关问题