[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

git-cache-proxy (in chiark-scripts 4.3.0)



chiark-scripts now contains a program called "git-cache-proxy", which
does what its name suggests.  I thought people might find this useful
enough that it would be worth plugging it here.

The doc comment follows.

Sadly there is no manpage yet, and it isn't suitable for exposing to
completely untrustworthy clients since it can probably be DoSsed by a
sufficiently broken (or sufficiently malicious) client.  I have ideas
about how to fix that, but it involves a lot more code than there is
right now.

(4.3.0 is in incoming right now; source already available from alioth
with dgit.)

Ian.

# git caching proxy

# Suitable only for exposing to semi-trusted clients: clients are not
# supposed to be able to take over the server.  However, clients can
# probably deny service to each other because the current
# implementation is not very good at handling various out-of-course
# situations (notably, clients which are too slow).

# usage: run it on some port, and then clone or fetch
#  "git://<realhost>:<realport>/<real-git-url>[ <options>]"
# where <real-git-url> is http://<host>/... or git://<host>/...
# and <options> is zero or more (whitespace-separated) of
#    [<some-option>]      will be ignored if not recognised
#    {<some-option>}      error if not recognised
# options currently known:
#    fetch=must           fail if the fetch/clone from upstream fails
#    fetch=no             just use what is in the cache
#    fetch=try            use what is in the cache if the fetch/clone fails
#    timeout=<seconds>    length of time to allow for fetch/clone

# example inetd.conf line:
#  9419 stream tcp nowait git-cache /usr/bin/git-cache-proxy git-cache-proxy
# you'll need to 
#  adduser git-cache
#  mkdir /var/cache/git-cache-proxy
#  chown git-cache /var/cache/git-cache-proxy


Reply to: