Sriram Venkatesh
Sriram Venkatesh

Reputation: 593

Is there a way to restrict push access to users on a local git repo?

In the currently workflow, we have a centeralized git repo. This git repo is supposed to be "blessed", where code is heavily QA'd and Verfied. This means any developer is not allowed to push to this blessed repo, the only entity that is allowed to push to this blessed repo is Gerrit. I have treated Gerrit as a gatekeeper, but from a secuirty aspect the devleoper could bypass this and push directly to the blessed repo.

Upvotes: 0

Views: 3117

Answers (1)

iltempo
iltempo

Reputation: 16012

Never trust those evil developers! They are pushing code everywhere. ;-)

The git-scm page very extensively explains how to enforce access using ACLs via git hooks.

Upvotes: 2

Related Questions