stagit

static git page generator  https://git.ce9e.org
git clone git://ce9e.org/stagit

NameSize
LICENSE1213B
Makefile827B
PKGBUILD229B
README.md3089B
data/git.nginx164B
data/style.css1607B
gitolite/shell.py962B
gitolite/stagit.py3792B
src/config.h273B
src/ctpl.py1231B
src/stagit.c.in19259B
src/strlcpy.c1599B

stagit

This is my personal fork of stagit combined with access control scripts inspired by gitolite. Together they are a simple yet powerful solution for hosting git repositories.

Installation and setup

$ make
$ make install

Then setup access control:

stagit.conf

[private]
ssh  = admin dilbert
post-update = git --work-tree=/var/www/example checkout -f master

[example]
desc = my shiny new project
ssh  = @all
http = yes

Authorized keys

The authorized keys file should look roughly like this:

command="/usr/lib/stagit/shell admin",no-port-forwarding,no-X11-forwarding,no-agent-forwarding,no-pty ssh-rsa … admin@example.com
command="/usr/lib/stagit/shell dilbert",no-port-forwarding,no-X11-forwarding,no-agent-forwarding,no-pty ssh-rsa … dilbert@example.com

It is mostly a regular authorized keys file with some restrictions. Most importantly, the user is restricted to the stagit shell, so no regular shell access is possible.

Note that the stagit shell gets the username to use as first argument.

Differences to the originals

Customization

The source code is meant to be hackable, so feel free to mess around.