This is an old revision of the document!
Table of Contents
Managing Gitosis Repositories
Author: John Reese
Concepts
Gitosis stores repositories in the 'git' user's home directory. In the case of git.mantisbt.org, this path is /srv/git
. Configuration of the hosted repositories is defined in a special repository gitosis-admin.git
, which contains a single configuration file and a directory of users' SSH keys.
Gitosis does its magic via the post-update
hook in the gitosis-admin
repository; in other words, every time you push changes to the special repository, it automatically updates all the appropriate settings, files, etc on the server to match the new configuration.
Repository Management
This process assumes you have been granted admin access to Gitosis on the server.
General Process
Start by cloning the gitosis-admin
repository. Naturally, you only need to do this once; any later changes to the repository can be handled using the same clone.
$ git clone git@mantisbt.org:gitosis-admin.git
Now that you have a successful clone, you can make your changes. Once you're done making changes, commit your changes, and push them back to the server.
$ git commit -a -m "<What you just did>" $ git push
Gitosis will then handle updating all the repositories appropriately. You're done!