networking - How to Make a git Repository 'pull only' -
i setting development environment on shared server multiple developers. have 1 repository houses code used in production, , many others used development different members of team. production repo 'pull only'. users can pull , production changes locally whenever want, pushes need handled production admin, or @ least require password. like:
[user@machine /devroot/myrepo]$ git pull $production master <location> *branch master -> fetch_head up-to-date [user@machine /devroot/myrepo]$ git push $production master error: user `user` not authorized action
or
[user@machine /devroot/myrepo]$ git push $production master head @ `$production`-please enter password:
i believe file permissions, doesn't strike me elegant solution. git have built in?
if want complex repository access controls, may want gerrit. primary focus code review (which totally worth having well!), access control side effect.
otherwise, if want simple, file permissions way of handling on single machine. long user can't write files in directory containing repository, can't push it. see nothing inelegant @ all!
Comments
Post a Comment