Git Repository in ZeroNet

in #zeronet5 years ago (edited)

ZeroNet, a serverless P2P network that uses Bitcoin cryptography and BitTorrent technology, may be the first real, usable prototype of a decentralized web.

BitTorrent users can download files directly from other users, without needing a central server. The BitTorrent technology for distributed file storage and peer-to-peer transfers, one of the biggest developments in Internet technology since the Web itself, opens the way to a distributed, fully decentralized Internet. 

Here's an example how to publish a serverless Git repository: 

Note: Only private key owner can push, sign and publish changes. However other users can clone repositories even if internet connection is offline.

Create a new site as described here

Make a mirror of your existing repository

git clone --mirror $PATH_TO_YOUR_ORIGINAL_REPO

Clone mirrored repository to any other directory


Set up your post-update hook for "dumb http"

cd $REPO_NAME/hooks
mv post-update.sample post-update

Make any minor change (e.g. add one line to a >> file)

echo "" >>

Commit and push your changes

git commit -a -m "Technical commit"
git push

Sign and publish site changes as described here.

Now you can clone your repository from ZeroNet

git clone$REPO_NAME.git

Here is a working demo: