Host your own git
I have a personal git server for several years now, but I’ve used GitHub for “brag” code. It was easier, GH is well known and I could even collaborate with others from time to time. However, recently GH has, not blocked me as I could still manage my repos and commit code, but flagged my account. Which means it was not visible to the public. There was no email notification about it. I’ve noticed it only after I’ve visited GH via browser. I was working on a new code for some time, but haven’t noticed as I was using SSH. So, I’m not even sure when I was flagged. And why? They say it was bot marking me by mistake, but then why now?
Anyway, I’ve submitted a ticket to GH support, but they were busy, so waiting time was 7 business days. However it’s taken them more than 7 business days in the end. At first I was waiting, although impatiently. But then I’ve though. OK, they would unblock public visibility of my account. But nothing can be done to not allow for this situation to reoccur. I’ve decided that I need to host my “brag” code on my own. Somebody on IRC has suggested gitea. But I didn’t like the setup stage, so I’ve kept looking and found gogs. My first installation wasn’t successful, but I’ve read a little and got it working. You can find my repositories here.
If you’ll be setting up gogs on your server I have a tip for you. Use built-in SSH server as described in point 2 here. You’ll save yourself some time and database manipulation.
Another advice. Because I don’t like to expose such apps directly to the internet, I’ve hidden it behind proxy. It’s also easier to manage this way. But because of that it wasn’t possible to clone a repo via HTTP. But there’s solution, just add ENABLE_REVERSE_PROXY_AUTO_REGISTRATION = true
to [auth]
section of your app.ini.
Of course, hosting repos on your own has disadvantages. They won’t be as reachable as on GH. Because everybody knows about GH, but that’s not true about your server. Collaboration would suffer as people would have to have additional account, plus I’ve disabled registration on my server. So actually, there won’t be any collaboration. I’ll also have to make additional backups. But these are the things I can live with. And my repos weren’t very popular anyway.
I’ll keep my repos in both locations for a while and will see how it goes. Especially that you can have more than one remote for single local git repo, so it’s effortless to push to both locations. Definitely maintaining gogs would require more effort than GH, as latter is effortless. But it should be beneficial. I hope. Time will tell.