无法为azure移动应用安装npm模块

iecba09b  于 2021-06-20  发布在  Kudu
关注(0)|答案(0)|浏览(256)

有人能帮我为azure移动应用安装node.js模块吗?
我想在我的azure移动应用程序中使用azure存储。我尝试了以下两种方法,但得到了相同的错误:
1安装在kudu终端(npm安装“azure存储”)
2在包json中添加“dependencies”模块并从本地git推送(“azure存储”:“>=1.1.0”)

remote: npm ERR! node v4.2.3
remote: npm ERR! npm  v3.5.1
remote: npm ERR! path D:\home\site\wwwroot\node_modules\azure-storage
remote: npm ERR! code EPERM
remote: npm ERR! errno -4048
remote: npm ERR! syscall rename
remote: Failed exitCode=-4048, 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:
remote: An error has occurred during web site deployment.
remote: npm ERR! Error: EPERM: operation not permitted, rename 'D:\home\site\wwwroot\node_modules\azure-storage' -> 'D:\home\site\wwwroot\node_modules\.azure-storage.DELETE'
remote: npm ERR!     at Error (native)
remote: npm ERR!  { [Error: EPERM: operation not permitted, rename 'D:\home\site\wwwroot\node_modules\azure-storage' -> 'D:\home\site\wwwroot\node_modules\.azure-storage.DELETE']
remote: npm ERR!   errno: -4048,
remote: npm ERR!   code: 'EPERM',
remote: npm ERR!   syscall: 'rename',
remote: npm ERR!   path: 'D:\\home\\site\\wwwroot\\node_modules\\azure-storage',
remote: npm ERR!   dest: 'D:\\home\\site\\wwwroot\\node_modules\\.azure-storage.DELETE',
remote: npm ERR!   parent: 'azure-mobile-apps-quickstarts.backend.node.EmptySite' }
remote: npm ERR!
remote: npm ERR! Please try running this command again as root/Administrator.
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.

在我今天遇到这个错误之前,我在kudu终端中使用了“npm install”,看起来一切正常。
有人知道怎么解决这个问题吗?
谢谢你的帮助,谢谢。
更新package.json

{
  "engines": {
    "node": "=4.2.1"
  },
  "name": "azure-mobile-apps-quickstarts.backend.node.EmptySite",
  "version": "0.0.1",
  "amax_version": "2.0.19.160727",
  "description": "Samples for Azure Mobile Apps",
  "author": "Microsoft",
  "repository": "Azure/azure-mobile-apps-quickstarts",
  "license": "MIT",
  "dependencies": {
    "express": "^4.13.0",
    "azure-mobile-apps": "^2.1.0",
    "azure-storage": "^1.1.0",
    "sendgrid": "^3.0.11"
  },
  "devDependencies": {}
}

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题