Code your own Multi-User Private Git Server(moocode.com) |
Code your own Multi-User Private Git Server(moocode.com) |
Edit: Hah! That's basically what it is, just dressed up with a tiny script and the two-factor trick from last week. Never mind then. This is sane. Just maybe oversold.
Gitolite is a great project and it has many useful features such as branch-level access control. That might be what he meant by "overkill". He simply didn't need those features. I think there's much to be said for keeping things simple.
My intentions were that you could read the article in 5 minutes and the code sample would give you a good starting point to code your own implementation.
What's important to note is that this also talks about SSH_ORIGINAL_COMMAND, which is the environment variable set by sshd when invoking the forced command that is specified in authorized_keys.
Clever hack.
root@server# apt-get install git-core
git@server$ mkdir ~git/repo.git
git@server$ git init $!
user@client$ git remote add origin ssh://git@server/repo.git