pratikju / servidor

A smart light-weight git http server
MIT License
48 stars 10 forks source link
git git-server golang http

Servidor

Servidor is a light-weight no-database git http server following git smart HTTP protocol. You can do all kind of git remote operations like push, pull, fetch and clone. Host the server very easily and get started.

Features supported as of now

Demo

More screencasts

Motivation

While setting up our project a few months back, we had to go through the trouble of setup and configuration needed in GitLab. To do away with all of that in future, I decided to create a git server of my own. It will typically help small group of coders, who wish to maintain private repositories within a local network and don't want to do all sorts of setup needed in GitLab and other providers.

Installation

Getting started

Start the server by executing servidor binary. By default, servidor will listen to http://localhost:8000 for incoming requests.

Options:

./servidor -h
Usage of ./servidor:
  -R    Set Whether ReceivePack(push operation) will be restricted
  -U    Set Whether UploadPack(clone, pull, fetch operations) will be restricted
  -a    Enable basic authentication for all http operations
  -b string
        Hostname to be used (default "0.0.0.0")
  -c string
        Set the path from where the password file is to be read(to be set whenever -a flag is used)
  -g string
        Mention the gitPath if its different on hosting machine (default "/usr/bin/git")
  -p string
        Port on which servidor will listen (default "8000")
  -r string
        Set the path where repositories will be saved, Just mention the base path("repos" directory will be automatically created inside it) (default "/home/administrator/servidor")
  -s    Enable tls connection

Usages:

Setup for extra features

API References

Feature to come

Libraries Used

License

MIT, see the LICENSE file.