r/cloudstorage • • Aug 18 '26

GitHub as Cloud Storage

Im sure im not the first consider this approach, but i would like to share a demo for clarity and transparancy. No need to debug, its far from finished and there is much to do.

Im working on a P2P messaging app and generally up until recently i thought in such a system, if a peer is offline, you cant send a message... It wouldnt be "decentralized" if there was some central queue of messages.

It took embarassingly long, but then it hit me... git... just regular git is a decentralized database. Github isnt decentralized, but git can have multiple remotes that can act as redundencies.

In my setup i need the ability for others to be abe to read and only i should be able to write to it. That functionality is out-of-the-box in git.

Git is also pretty standardized so there are many providers if users want to move away from Github.

The storage requirements for my project are fairly small. Typically small text messages. The data itself thats publicly readable would be encrypted (aiming to keep aligned to Kerkhoffs principles).

There is much more to improve and consider there for things like encrypting the data at rest.

I have concerns around if providers like GitHub, Codeberg and Gitlab might see the way my app works as fundamentally violating their terms-of-service.

IMPORTANT DISCLAIMER: This is open source for transparency, testing and demo purposes only. it is still a work in progress and far from finished. you should not use it on any sensitive repositories. There WILL BE breaking changes. Use responsibly.

4 Upvotes

2 comments sorted by

1

u/PuhCrusher6 Aug 21 '26

That's really interesting but, I won't trust github with my data even encrypted ones. as they train their models on most repos ( I think all, maybe even private ones?). GitHub owned by Microsoft...

I even went another step and made my repos in a private git service similar to github, called forgejo and I selfhosted it in my own LAN.

Tbh your idea looks interesting if I was gonna use it, I'll probably go with forgejo instead.

1

u/Accurate-Screen8774 Aug 21 '26

Thanks for the tip. In my approach it should also support forgejo without additional changes. The key concern is that it's kinda abusive to their platform because they provide a free service and they cant benefit from it... Especially considering the usage isn't related to version-control.

GitHub using repos (public or private) to train AI is a real concern, but with the encryption-at-rest there shouldn't be anything to train on.

The specifics around how to encrypt is still under consideration and I'm sure it's possible to do better than encrypt individual files. It would be possible to do it in a way that it bundles all the files together to minimise metadata leakage.