Git推送错误:无法创建' /tmp/project/refs/heads/master.lock':权限被拒绝

时间:2016-08-11 11:48:26

标签: git

我正在尝试将存储库从Git服务器推送到本地git存储库并获得以下错误:

$ git push origin master
Password:
Counting objects: 3, done.
Writing objects: 100% (3/3), 211 bytes | 0 bytes/s, done.
Total 3 (delta 0), reused 0 (delta 0)
remote: error: cannot lock ref 'refs/heads/master': Unable to create '/tmp/project/refs/heads/master.lock': Permission denied
To ssh://tmpuser@cltprfusapp04:/tmp/project
 ! [remote rejected] master -> master (failed to update ref)
error: failed to push some refs to 'ssh://tmpuser@cltprfusapp04:/tmp/project'

1 个答案:

答案 0 :(得分:0)

您的用户似乎没有权利cltprfusapp04 tmpuser推送chown -R tmpuser /tmp/project

如果您有正确的权利,请向管理员询问app.use(errorHandler); function errorHandler(err, req, res, next) { // XHR Request? if (req.xhr) { logger.error(err); res.status(500).send({ error: 'Internal Error Occured.' }); return; } // Not a XHR Request. logger.error(err); res.status(500); res.render('framework/error', { error: "Internal Server Error." }); // Note: No need to call next() as the buck stops here. return; } 或自己动手。