Book Image

Gitolite Essentials

By : Sitaram Chamarty
Book Image

Gitolite Essentials

By: Sitaram Chamarty

Overview of this book

Table of Contents (19 chapters)
Gitolite Essentials
About the Author
About the Reviewers

Redirecting pushes

We mentioned earlier that there can only be one master repository. However, this makes things a little inconvenient from the developers' point of view. Say you would like some of your developers to take advantage of a geographically close slave server to pull updates from. This means they would have to use push to a different server than the one they presumably cloned from and regularly pull/fetch from. While Git does allow this (see man git-config and look for pushurl, for one possible way), it is still something that requires each user to do something on their machines. In addition, remember Gitolite allows different repositories to have different master servers; this is more scope for confusion on the part of the developer.

Therefore, Gitolite has a feature that makes this restriction much less onerous. If the administrator chooses, a developer can push to a slave server, and the push will transparently be forwarded to the master server for that repository. In fact,...