⚠ WORK IN PROGRESS ⚠ Like onionshare, but for git repos. Instead of hosting your project (only) on github or the like, host it on a swarm of onions! ⚠ WORK IN PROGRESS ⚠

fnordomat 29d6add3f6 cleaning up 4 years ago
docs fd63041dad conceptual work 4 years ago
oniongitshare 29d6add3f6 cleaning up 4 years ago
scripts bd9932df82 working on jinja template 4 years ago
stubs 0a5c9ae23f argparse instead of optparse (deprecated) 4 years ago
test 29d6add3f6 cleaning up 4 years ago
HISTORY.md bfbeb29a8e Create HISTORY.md 4 years ago
ISSUES.md 646822c613 v 0.0.6.2 8 years ago
LICENSE 278040525b Initial commit 8 years ago
MANIFEST.in 063a4c4d13 towards #21: serving jinja2 templated html patterned after gogs / gitea 4 years ago
README.md c53e05f1aa towards more testing -> more testable code 4 years ago
mypy.ini 0a55533a36 made mypy stub file for gnupg package (https://bitbucket.org/vinay.sajip/python-gnupg/src/master/gnupg.py) 4 years ago
setup.py 29d6add3f6 cleaning up 4 years ago

README.md

oniongitshare

Work in progress

Like onionshare, but for git repos.

Distributed githubless repository sharing. Put the "D" back in DVCS!

oniongitshare is an attempt to ease the distribution of git repos away from central points of failure. It makes it easy to host git repos on a distributed swarm instead of just one central server. Each instance manages a single git repo (for now).

Nodes can come and go, and network topology only depends on the peers entries in the nodes' config files. Changes that are merged by one's peers propagate by diffusion.

Future plans: oniongitshare is meant to evolve into an experimental distributed asynchronous collaboration platform. This means issue tracking and everything else.

Come join the effort! Try it!

Usage

Make a new directory and put this in the file ./repo.cfg (when creating a new repository instead of cloning from a peer, the list or indeed the repo.cfg file can remain empty)

[network]
peers = <comma-separated list of onion domain names, with or without the suffix .onion>

For a public repository, no authentication (option -x) is needed. In case authentication is used, prepend the secret as follows: somebody:secret@peeroniondomainname.onion.

For each shared repo, Globalist will create one .onion service. Note that it is possible to use either bare repos or not-bare repos.

To initialize a new blank repo and an onion address for it (using the current directory to store the config and repo):

oniongitshare -i

To clone a bare repo:

oniongitshare -c ...

To pull once from a bare repo:

oniongitshare -p

There are various other options and parameters, which you can view:

oniongitshare -h

For example, this uses /srv/oniongit/foobar as base directory, starts its own tor process under /srv/oniongit/foobar/tor, communicates with it via the given port, and starts serving:

oniongitshare -T /usr/bin/tor -C 9251 -d /srv/oniongit/foobar

If you initialize a new oniongitshare instance with -i or -c, then an onion address will be generated automatically that you can start handing out immediately. This is persistent and will be re-used anytime you serve from the same directory. No need to configure tor manually!

To install locally

You need the pip3 package setuptools, the rest will be downloaded automatically.

./setup.py install --user

or

torsocks pip3 install -v -e .

See also

Related projects

https://blog.printf.net/articles/2015/05/29/announcing-gittorrent-a-decentralized-github/ https://safenetforum.org/t/safenetwork-git-portal-discussion/32793

Run tests

python3 -m nose test/itest.py -s -v --with-coverage --cover-html --cover-branches --cover-package=oniongitshare

To do

Ideas, further work, TODOs:

  • destructive update (removal of commits and refs) requires concept for metadata and specifications and protocols for metadata management.
  • also manage maintainers, issues, PRs, forks
  • what about the security of the git daemon?
  • make user aware of the importance of signed commits when using software from untrusted sources!
  • support overlay networks other than Tor
  • support version control systems other than Git
  • improve UX
  • improve things overall, become foolproof
  • popularize the approach: become self-hosting