I said this before many times and I'll say it again, consider self-hosting your projects on a solution like GitLab or Gitea to avoid this sort of situation. [0]
GNOME, Xfce, Redox, Wireguard, KDE and Haiku all have self-hosted on either cgit, Gitlab, Phabricator or Gitea.
I used to help maintain Xfce's svn and then git server.
I'm not going to say it was hard, but it was work, and it was work that took time (time that was volunteer free time) away from working on Xfce itself. When I did the final git imports of our svn repos in mid-2009, GitHub had been around for about a year, maybe a year and a half, and wasn't that popular yet. And I suppose back then I had the bull-headed "must self-host because that's the only thing a respectable open source developer should do".
That was a foolish attitude that took time away from the actual goal, which was making Xfce better. If it were today, I would have moved us to GitHub in a heartbeat, or perhaps GitLab (their hosted offering; I wouldn't self-host), instead. I haven't been involved with Xfce (still a happy user though!) in nearly a decade, but I suspect they still self-host out of inertia, with probably a little of that bull-headedness mixed in (that I myself can't claim to be fully free of either).
While GitHub's uptime isn't perfect, it's pretty damn good, and better than most volunteers will get running their git server off a single box someone had racked somewhere in Belgium, which I believe was what we were doing at the time. Tools for that sort of thing are better now, and if I had to self-host today, I'd use EC2 or something like that, and automate the hell out of everything, but it's still a lot more work than just using somebody else's infra.
The downside is that a lot of these self hosted archives will have disappeared 10 years from now.
Meanwhile, I expect many forgotten repos to remain online with Github one way or another for a very long time.
If you do go the self-hosting route, add a mainstream host as an additional remote and push your commits to both.
This is a huge reason why they are making MaidSAFE. Anyone remember Freenet?
Correct http://dweb.happybeing.com/blog/post/002-safegit-decentralis...
How far along is safenet? What can it do today, in terms of its parts?
No guarantees either way - Google Code was alive and kicking, until it suddenly wasn't.
I do appreciate how easy git and other dvcs make it to mirror repositories, though. I find myself using Github mirrors of projects that are otherwise self-hosted, just because the code search works on Github works pretty well.
But the content is still available isn't it: https://code.google.com/archive/
When people try to self-host and get lazy or hit by a bus, the content just disappears unless it was lucky enough to get archived.
Funny, I find myself cloning GitHub repos just because code search on GitHub works pretty badly (e.g. it doesn't pick up partial tokens). Haven't had the chance to compare to other solutions though.
Is there something like archive.org but for git (and why not other vcs) that finds repos and periodically fetches?
The easy solution to this is that git supports pushing to multiple remotes: https://news.ycombinator.com/item?id=23818609
In fact, with all these free services, I'd probably say it's well worth automatically making remotes (at least) for GitLab, GitHub and having a local Gitea for everything you do. This should be resilient against specific outages, or GitHub simply deciding they don't like your project name, or some other disaster.
Self-hosting is hard work, you easily forget security updates, or backups, and should your project get a lot of traffic your server might not handle it.
And should your project go unmaintained it'll probably disappear if you don't have managed hosting.
True, but the burden of maintenance and up-time is on yourself then...
Might be good to have a self hosted backup that's automatically synced with Github
You can easily do the latter with Gitlab, free for open source projects.
How about a more low-tech solution? I don't want/need a full-blown web application like Gitlab, just need somethings than auto-syncs my public and private repos so that i can still access everything when Github is down.
Any ideas?
SSH and git-shell might be enough.
https://git-scm.com/book/en/v2/Git-on-the-Server-Setting-Up-...
The lowest tech solution is to just wait until the outage is over. It’s 100% free!
Seriously, though, any repo that I work on regularly will be cloned to my local dev environment, so it’s not a hard blocker.
That said, a cron job on a cheap VPS would probably do the trick.
Moreover, GitHub will eventually get these outages under control. Or we'll all be driven to gitlab :)
It's still a full full blown web app but I can highly recommend gitea. It's just a single binary so getting setup is really easy. I run an instance and it literally requires no maintenance.
Just add another git remote push URL so that your commits are automatically mirrored when you push:
If you are working alone on these projects, store bare git repository in Dropbox and/or similar services that sync data through all your devices.
If more privacy is required, you can use something like gocryptfs to only send encrypted data to these services.
Syncthing is a similar option that doesn't require an external service, also doesn't require local encryption since all data in transit is always encrypted.
This has a big caveat though: there's no locking mechanism that will work reliably on the bare git repo, so you may have to resolve some conflicts manually if two separate devices push to the same git repo at the same. This is why you should only use this method of you work alone on these repos.
never trust external tools in your build process, you may have an emergency and not be able to fix.
we are trying to migrate to https://www.sonatype.com/nexus-repository-oss (self hosted), it would cache the git tags and you just have to replace the git links to nexus like in the dependency manager.
if you want something simpler, you can try satis for php, sinopia or verdaccio for npm packages. you will find a lot of other tools for the other languages.
A lot of people posting complex things. All you need is SSH.
For the syncing part. If you don’t want to do it manually, you can add multiple destinations on the same remote. Someone already mentioned it here, https://news.ycombinator.com/item?id=23818609, https://jigarius.com/blog/multiple-git-remote-repositories
Sure, if you're a big project. But smaller ones I bet would have less downtime, require less ops, require thinking less about everything.
I wouldn't consider self hosting better with regards to downtime. Our company has various self hosted components like jenkins and all and full time people to manage that, and I can say for sure their downtime is more than github. And good luck if you think you can manage everything for a side project.
No, the main point of programming for me is to fill up the activity graph on GitHub. Without that I may just as well quit.