EACCES: permission denied / code -504002

发布于 6 年前作者 yangfang8676 次浏览最后编辑 6 年前来自 ask

你好大家,

I cannot find a solution to the error below. Can anybody help with that?

VM1437:1 [云函数] [login] 调用失败 Error: errCode: -404011 cloud function execution error | errMsg: cloud.callFunction:fail cloud function service error code -504002, error message EACCES: permission denied, open '/var/user/index.js'; at cloud.callFunction api;
    at new t (WAService.js:22)
    at o (WAService.js:22)
    at Object.i [as returnAsFinalCloudSDKError] (WAService.js:22)
    at Function.success (WAService.js:21)
    at Object.success (WAService.js:4)
    at L.<anonymous> (WAService.js:7)
    at L.emit (WAService.js:8)
    at Function.<anonymous> (WAService.js:12)
    at WAService.js:6
    at e (appservice?t=1557377240982:1375)

Best

George 乔治

2 回复
ping75
ping751 楼6 年前

@光 thank you for your help!

I found the solution and post it here in case anyone faces the same error message. My cloud folder didn’t contain the “config.json” files which include permissions.

After i created those files and redeployed them to the cloud the error was gone.

WXOPEN Club 内容图片
xiuyingdong
xiuyingdong2 楼5 年前

Maby it’s because you didn’t open the permission of cloud development ? I saw “permission denied” in your error message.