Some thoughts on personal Git hosting

shkspr.mobi

102 points by ColinWright 6 days ago


NoiseBert69 - 3 days ago

I have no problems publishing my public projects on GitHub or Codeberg. Secretly hoping that LLM-Crawlers will choke to dead on my bad code.

But private stuff runs on my own servers.

In 2025 it's mostly maintenance free once the setup is running: Debian will be updated fully automated using unattended-update and the hosted application when there's the need to do one manually. Backups automatically every night using Proxmox and its little brother Proxmox Backup Server. Even with valid certificates using DNS-Auth from Lets Encrypt.

monegator - 3 days ago

All the drawbacks are not drawbacks to me. My projects, my repos, my private server. I don't want nor need to show off ("collaborate") and if i did.. what's the point of self hosting then? Just use github/gitlab/codeberg.

I don't even need to rent a server for that. Everything runs on my router (openWRT is amazing)

strogonoff - 3 days ago

I never quite understood why’d people call for “federated forking” when the truly decentralized model had existed since forever: simply clone the repository to your machine, change what you want, create a patch, and communicate it to maintainers (traditionally Linux kernel used a mailing list for that, but imaginably you could use something in Fediverse, Git doesn’t care). Everybody gets to use their favourite tooling and no one is locked to lowest common denominator GUI for things like reviewing proposed changes.

divbzero - 3 days ago

> You can git clone the repo to your local machine, and you can manually move it elsewhere, but there's no way to send a PR from your repo to mine.

There is a native git request-pull command [1] that generates a summary of pending changes to pull into an upstream project, but it doesn’t enjoy support for all the features offered by GitHub pull requests or GitLab merge requests.

[1]: https://git-scm.com/docs/git-request-pull

skydhash - 3 days ago

> Suppose you want to make a Pull Request or just take a copy of the code. At the moment, you have to create a fork on my server. There's no way to easily fork something to your GitHub or personal server.

Why are people so keen on having that network graph of forks? It's not necessary for collaboration. Status symbol?

account42 - 3 days ago

While less popular these days, email-based workflows don't have the account/federation issue - anyone can just drop by and post a patch series. Of course the workflow itself is going to be an obstacle for most but I'm not sure if that's inherent or only because it's not what people are used to.

zokier - 3 days ago

> You can git clone the repo to your local machine, and you can manually move it elsewhere, but there's no way to send a PR from your repo to mine

Have people forgotten that email exists?

lloydatkinson - 2 days ago

Not to sound all salty and sarcastic, but I also wrote a blog post reviewing some of the popular Git self hosting options and it barely got any attention.

Since then there seems to be an uptick in blog posts that seem to have less content talking about the same things.

I guess I just talk into a void.

OhMeadhbh - 3 days ago

Fwiw.. I have a "normal" private git server over SSH, but for public projects, it copies merges into blessed branches to public, read-only repos accessible via HTTPS. Here's an example:

https://www.bi6.us/GI/B/

I sort of punted on receiving patches and merge requests because most of the projects I'm distributing in this way aren't really open source, but "published source" and there's a small community of people who use them. The people who use the public, read-only repos know how to generate patches and distribute them via email or (in one case) uploading them to an S3 bucket.

Anyway... your mileage may vary, but it's worked reasonably well for a small community. Not sure I would recommend it for a huge open source project.

eviks - 3 days ago

> 1. Leave my popular / sponsored repos on GitHub > 2. Move my smaller repos to https://git.edent.tel/

Wouldn't 2. make transitioning them into 1. "impossible"?

calvinmorrison - 3 days ago

Github steals my software, the 'software conservatory' steals my software, etc.

I dont want it in a vault, I dont want you to do anything other than read it on my site. I dont want an archive. most of my code is not licensed. All rights reserved.

It's there as a personal portfolio that's it.

And these scanners don't respect the LICENSE file, they think if its on the web - they can not just index it but make full copys and reproduce it.

dinkleberg - 3 days ago

I got the self-hosting bug a few years back and have been running a gitea server (among many others) on a mini PC running in my basement that is setup with tailscale so I can connect to it from anywhere, and it has been fantastic. For any OSS projects that I want to be open to the world, I still put it up on GitHub. But for anything else, it is just going on my Gitea instance.

abound - 3 days ago

For my private, personal Git server, I recently moved from Gitea to Soft Serve [1], and have enjoyed how light and fast it is. I have it hooked up via Tailscale (using TS_DEST_IP to forward traffic [2]), so it has its own IP on the network and I don't have services fighting for port 22.

TUI tools over SSH definitely aren't for everyone, but if that's your style and you want a place to dump all your non-public projects, it's a great choice.

Most non-private stuff goes on Sourcehut, and anyone can contribute via email (i.e. without any account) assuming they don't mind going through the arcana required to set up git-send-email.

[1] https://github.com/charmbracelet/soft-serve

[2] https://hub.docker.com/r/tailscale/tailscale

akkartik - 3 days ago

Critical data here is how many PRs one is creating on others' projects and receiving on one's own projects. To me OP sounds like "Lifestyles of the Rich and Famous." At my level of git collaboration, just git push contributions on any code forge and send me a link, and I'll do the work to pull it in wherever I am.

dividedcomet - 3 days ago

I love hosting my personal git, so glad to see others do! I use it for certain projects that I just want to be lazy about (personal website with sensitive data committed to the repo) projects that are for friends/family and don’t need to be public. I chose gitea maybe 2 years ago? And it’s been great. Very light weight compared to gitlab, with useful things like actions. So I can push a new commit to main on my personal server and it’ll deploy my website to the server. I still publish things I want to share to GitHub, but not everything.

I think the thing that sets it apart from others would be I run it on a m2 Mac mini? Very low power consumption, never makes any noise, and seemingly has plenty of power for whatever I need to get done.

leephillips - 2 days ago

So much here. If I have some personal code that I want to share I just use Git, like on this page:

https://lee-phillips.org/vortex/

mixcocam - 3 days ago

I think that the best way to move away from github is to go full chad and doing mailing list with patch submissions à la LKML.

impure - 3 days ago

GitLab is open source, you can self host it. Although the system requirements are quite high, you will not be able to host it on a two euro VPS.

And I wouldn’t be that concerned about contributors. It’s only the very top projects that get any contributors. And even then most of the time contributors are not worth the hassle.

BatFastard - 3 days ago

I recently began running Gitea on my NAS to host an unreal5 project which requireds significant LFS, Github's free LFS limits are very small. And honestly trying to decipher their paid account limits was too much for my old brain that day.

Anyone have experience with LFS on other repos?

kwar13 - 3 days ago

I've tried the same thing and couldn't quite move away from the network effects of Github.

ghosty141 - 3 days ago

gitweb + gitolite is all you need in my opinion for hosting private projects. I have had a wonderful experience with it since there are no complex databases, config files etc and it’s very light on resources

goku12 - 3 days ago

There are two unresolved problems preventing us from effectively replacing github or similar centralized forges with a fully decentralized/self-hosted ecosystem. These are the factors that keep pushing people back onto those platforms.

Note: Please add any major issues that you consider as a blocker. And, apologies for repeating some points that I expressed in other comments. I wasn't planning to write a top level comment.

So, Problem 1: Discoverability and network effects. This is the main reason why people keep going back to the largest platforms. There is practically zero chance of being seen or helped on self-hosted or small platforms. And this isn't because of a missing technical innovation either. Those platform has the size and first-mover advantage. What we need is a single feature-rich search interface to query all those projects spread over the net. That would need an index. Unlike the interface, the index itself can be distributed or replicated to avoid centralization. It should be able to store structured information about projects, like instructions (readme, usage, contributor guidelines, license text, CoC, etc), license, language, pull-request interface, issue tracker location, bug/security reporting information, project type, ownership details, signing information, etc. This will allow rich searches like what's possible on github and sourcegraph.

Problem 2: Communication channel. The biggest problem hindering distributed git hosting is a way to do pull-requests, code reviews, discussions, etc. Even with something like gitea, you need an account on every instance where you want to contribute. The truth is that we already have a communication channel that allows such a collaboration - email. We already have working proofs of how it operates at LKML and sourcehut. However, people have a particular dislike towards emails for git collaboration. IMO, this is actually the fault of email clients that absolutely massacre the elegance of plaintext emails. There are some powerful tools that's used with LKML that most people will never discover because of their hatred towards email. Sadly, email is a lost opportunity that could have been a delight with sufficient attention on the clients.

I have given up trying to convince people to give it a try. Email is somehow a taboo in this generation. So what else? There are projects like radicle (stable, more about it later) and forgefed (activitypub, under development) that try to build such a channel. But you really don't need to create such a channel for git. Git can adapt to any current channel (eg: xmpp/movim, nntp) using its extension mechanisms. Email was probably just the default channel. You can do patch pushes (git format-patch) and pull requests (git request-pull) practically through any such channel. With a bit of attention on the UI/DX, you can avoid the mistakes of emails (like html) that made them harder to use for our purpose. Additionally, you'll also need to build other development tools (issue tracker, code review, discussions etc) around them. People got too fixated on the platform approach and missed the possibilities of protocols.

Radicle: Honestly, I don't know what to make of it. It's a very impressive effort and they seem to have solved some very difficult problems. But radicle also seems to have gone for a platfom based approach and it encompasses everything. They seem to have an integrated issue tracker, CI system etc. If its scope was restricted to just a p2p network for discovering and exchanging git objects and other arbitrary information, we could have built a wide ecosystem of development tools on top of it. Radicle also feels like a darkweb that exists on a different plane from the web, though web bridges exist. For example, you can't do a clone of a repo from the net, unless it's bridged somewhere. However, I reserve my final opinion is reserved until I have a proper insight. I may have some wrong assumptions here. Please let me know if I do.

gitprolinux - 3 days ago

I simply use my own githosting product for my source code products at https://GitBusiness.com

worldsavior - 3 days ago

Why people self host a git site? If they're not an organization and are not looking for views, there aren't any reasons to self host.