Gitea: Open source, self-hosted GitHub alternative
gitea.io
gitea.io
gitlab is also so large it requires its own chef deployment to competently install it from omnibus, and has no HA roadmap in sight unless you want to break apart its rube-goldberg structure and attempt to HA the individual components of it.
Other things like Wiki, local runner CI, pages and integration with a corporate Jira ticket system seem like the excessive demands of programmers without enough skill to understand that there is tangible merit in ablating these systems into separate applications entirely and growing them as needed. gogs and gittea allow you to put the brakes on developers that just want to get the code out the door in order to study and implement competent things like competent CI, blue/green deploys, immutable infrastructure and reproduceable builds that target scalable platforms like Kubernetes instead of one-offs that just reward coders with a merciful standup and the chance to say "its done."
if you use gittea for no other reason, it is also massively less resource hungry than a gitlab installation. im currently throwing 4 cores and 8 gigs of ram at my gitlab install with another 2.3tb of disk and frankly no end in sight. The gitlab rake task for backups has sent oomkiller on a rampage 3 times so far and takes forever. Large installs of 1000 users or more and you'll begin to see why gitlab might not be the best choice. with programmers, the thirst is real...nobody cares about features if the repo wont clone.
BUT I very much disagree with your general rejection of it's worth. Yes, the feature set is ballooning, and some of them are very half baked.
But I find tremendous value in a integrated solution that offers code hosting, wikis, issue tracking and a tightly integrated CI without having to jump between 4 different systems.
There are a lot of use cases where Gitlab is overkill, but for others it is a really great solution that even comes for free.
Also, as long as the system has enough resources, I've found it to run very reliably and upgrades are painless. (I also agree though that the backup task is a PITA. Really slow and resource hungry).
Edit:
I would have to say if I were to choose GitLab the biggest reason would be the UI. The front-end just looks a lot better. If Gogs/gitea could get a sponsor to help clean it up it would be a lot more popular.
I'm looking for something that's self hosted, foss and does not require an admin to set it up for every project. GitLab offers this, but I haven't found anything that competes really.
We switched from GitHub to Gitea last year and love it. We looked at Gitlab but it reminded me too much of phabricator - trying to be all things to all people, bloating all over. I prefer specialized tools that focus on a smaller core of functionality and interoperate easily with the other pieces.
My mnemonic is that "dearth" looks like "death".
I'm thinking of the class of "Does:X, Y, Z" but Z requires unstated dependency of A and C, and C requires you to have a specific database organization type that was asked at the initialization of the system. And there would be no hint that you had to choose the DB type, and how that would have ramifications 10 steps down the line.
Going back, what I'd rather have is more in line with the Unix philosophy. Do something and do it well. Let me connect somethings to other somethings. But Gitlab is a cathedral, and disorganized at that.
Use the gitlab-ce docker container and save yourself the hassle. Literally takes less than 10min to set up and a version upgrade is nothing more than docker stop, docker rm, docker run <new version> away.
Only thing I haven't solved with this is HA but you can use a central NFS mountpoint with an HA'd setup there, and simply start a new container on another machine with the NFS mount... will require manual intervention, yes, but it's more efficient than trying to break up the dozens of moving parts.
We're working hard on a cloud native alternative to the docker container that works well on Kubernetes. There is more information on https://gitlab.com/charts/gitlab/ and you can see the activity on https://gitlab.com/charts/gitlab/commits/master Since it is cloud native I assume it will allow autoscaling and it neatly orders every component in its own container.
Today GitLab is using a lot of RAM and the best way to reduce that is to make the application server multithreaded https://gitlab.com/gitlab-org/gitlab-ce/issues/3592 The first priority is to add rubocop rules for https://github.com/covermymeds/rubocop-thread_safety There is a WIP merge request in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/1899 Any help is appreciated.
how is multi-threading helping with memory consumption?
But if manual intervention works for your setup, then you probably don’t really need HA anyway, just redundancy.
> gitlab [...] also [...] has no HA roadmap in sight unless you
> want to break apart its rube-goldberg structure and attempt to
> HA the individual components of it.
We run a very large in-house GitLab installation and the HA is easy
because:1) GitLab stores data on the FS, and you can outsource this problem to e.g. a NetApp filer.
2) The data it doesn't store on NFS it stores in psql or MySQL, which has established HA solutions.
Once you have that set up you can load-balance the GitLab nodes and provision / destroy them at will.
When Gitaly 1.0 lands you won't have to mount the NFS volumes on the application servers anymore as everything will go over gRPC.
I understand that this is something gitlab.com is working towards and excited about, presumably because it'll allow for provisioning web workers unrelated to the CPU you're spending on running git, but for us I don't see it being useful.
I hope GitLab eventually gets something like GitHub Spokes[1] which'll allow for provisioning the entire setup on a bunch of dumb boxes with RAID 0.
Spokes is more elaborate can can deal with node failure. We plan to rely on cloud storage so we can quickly attach a new VM with Gitaly.
I've got an OSX build box with a bunch of virtualbox VMs so I can build for Gnu/Linux (i386, x86_64, and arm), OSX, and Windows. Single slow box, so one runner at a time. It has to be running OSX because I haven't found any way to run an OSX VM on any other platform.
I want to trigger CI on Gitlab merge requests.
What does $competent_CI expand to?
Specifically: https://github.com/kstenerud/virtual-builders/tree/master/bu...
It is fairly easy to get decent OS X virtualization using Debian as base OS and QEMU-KVM for virtualization. You won't have niceties such as GPU acceleration but it will work.
Search for "OSX KVM" on Google, it will take you where you want - unfortunately a direct link would expose me to legal liabilities. Also, be warned that using this method may violate Apple's EULA.
They are fragile systems that one doesn't really want to risk production environments on in my opinion.
That’s an admittedly big caveat, but also one of the reasons why virtualizing OSX works in the first place.
Also, performance was atrocious. It was so bad as to basically make it unusable. 5 second delay before processing mouse and key events.
It's really handy when you are testing/adding support for projects (like C/C++ with cmake) on OSX.
Was this on a self-hosted instance or on GitLab.com?
We'd love to make sure this doesn't happen again.
The thing is, git, as our industry uses it, is not really a good tool for keeping artifacts, and "video" sounds like an artifact, not a source file. I'd like to see more artifact repositories, especially the ones that you can talk to from command line or from a Python/Ruby/whatever script. I haven't found any such thing, so I wrote my own.
From the features, GrailBag stores files along with key:value pairs as metadata (not surprising), has a command line client to list/modify/upload/download/delete the artifacts, and has a Python module for doing the same from a more sophisticated script.
Additionally there is an interpreter of a simple language that describes directory tree where artifacts will be deployed (which artifacts to download, how to name the files, what directories and symlinks to create). This way you can write a cron script that deploys whatever you have in the repository, e.g. in a cold-standby server scenario (two servers having the same configuration, but one shut down and only powered on when the first one fails; on the first run of the cron task, the spare server downloads all the missing files, including whatever got stored while the server was shut down).
I love gitlab. I have it running for a small team on a Digital Ocean Droplet it was trivial to get running. If we had gone for self-hosting we’d have gone the docker route. Having CI built in was a massive boon when we switched over. My only complaint really is the resource usage but it isn’t causing problems (8GB). Aside from that I love it.
Gogs: 24,564 stars, 602 issues, has a features list. https://github.com/gogits/gogs
Gitea: 5,971 stars, 733 issues, doesn't have a features list. https://github.com/go-gitea/gitea
Gogs features (from README):
Activity timeline
SSH and HTTP/HTTPS protocols
SMTP/LDAP/Reverse proxy authentication
Reverse proxy with sub-path
Account/Organization/Repository management
Add/Remove repository collaborators
Repository/Organization webhooks (including Slack and Discord)
Repository Git hooks/deploy keys
Repository issues, pull requests, wiki and protected branches
Migrate and mirror repository and its wiki
Web editor for repository files and wiki
Jupyter Notebook
Two-factor authentication
Gravatar and Federated avatar with custom source
Mail service
Administration panel
Supports MySQL, PostgreSQL, SQLite3, MSSQL and TiDB (via MySQL protocol)
Multi-language support (29 languages)
If anything, Gogs seems like a more polished product just by going through the README.Gitea with all its 2+ maintainers can't take care of that?
It's hard to do a comparison without that list. Are users expected to install and find out?
Why compare two products by their README and not their website? Heck, why not compare them by using their test instances that are there for you to try.
Gitea has every feature that Gogs had at the point when they forked it, plus a few that they've ported over.
But there are still features that have been in Gogs for over a year now that Gitea does not have.
One example that burned me earlier this year, Gitea's backup/restore feature is still very underdeveloped. Gogs' backup/restore feature has been capable of backing up and switching databases for over a year, while Gitea still can only backup and restore to a database of the same type (e.g. Postgres to Postgres)
Also, thanks for noting this. I had the mental perception that Gogs had really been fully surpassed by Gitea, and I need to re-evaluate now. Thanks.
Doubtful. IIRC it was somewhat of a hostile & opportunistic fork. The Gogs maintainer went on vacation or something and didn't reply to issues for a couple weeks so someone forked to Gitea and declared themselves the new mainline only for the Gogs maintainer to return and not appreciate the attempted usurpation.
You had that perception for good reason: it had surpassed GoGS. But they're both moderately active projects so it's good to revaluate regularly.
Gitea on the other hand was to be more of a community project with multiple maintainers and ways for active contributors to become one.
Though Gogs has more stars, and currently, I think, more related project/integrations, looking at GH stats, Gitea has more activity, PR's, commits, etc.
That made me choose Gitea over Gogs. Really content with it.. was planning on using Gitlab at first, but it would require AWS instances with double the oomph.
The documentation could be better, agree, but a search in issues or filing a Help wanted issue comes a long way.
Time?
https://public.gitsense.com/insight/github?r=gogits/gogs::go...
In the last 365 days, there were 54 unique contributors to Gogs
https://public.gitsense.com/insight/github?r=gogits/gogs::go...
and 136 unique contributors to Gitea
https://public.gitsense.com/insight/github?r=gogits/gogs::go...
When I was looking into switching from Gogs to Gitea, that is exactly what they expected you to do. I recall there being an issue saying that they won't compare the two because it's hard to keep up-to-date.
Which is a stupid excuse, considering it's supposed to be a community-based fork instead of run by one person.
If you want to compare Gogs and Gitea you have to compare the feature list.
> Are users expected to install and find out?
Some due diligence and going to the gitea website could also do the trick. https://docs.gitea.io/en-us/
I was mostly wondering why they don't have a list of features right there in their frontpage or inside the README on GitHub.
I remember that Debian considered Gogs to replace Alioth, but rejected it because of security concerns like injections (SQL XSS, etc).
I've also seen Gogs REST API behave badly when we tried to migrate/create a few hundred repositories using said API. Some of the repositories had special characters in their names, and the REST API accepted them without warnings. And after that the instance was pretty much unusable.
It was a while ago, but at the time, it seems that Gogs didn't do much input sanitization.
That said, I agree that Gitea should publish a features list and list the differences between the versions.
A good product is not defined by having a feature list.
I don't think a vision statement is necessary either since I'm a fan of developing software primarly for dogfooding, fixing problems you have is probably a good way to improve the software for others.
This sounds like a reasonable way for forking though. I mean what is open source for if you can't go and and implement your own features if you so desire. Sounds to me like both sides are at fault.
I would gladly switch back once Gogs is no longer vulnerable to the Bus-Problem.
It's not like other people are mentioning in the thread that "some contributions would not get added" - but rather the fact that he often has really long periods of absence: just take a look at the contributions on his profile https://github.com/Unknwon
And of course, I'm not putting the blame on him - all of us need breaks from time to time - but during these periods where he can't work on the project, the project is essentially brought to a halt, seeing as there is no one else in the community of contributors who is able to merge pull requests - even if they are critical.
I evaluated them both again a month ago and found that Gogs is as active or more active than Gitea by actual features developed, they just have less frequent releases.
Frankly, I'd have expected better from the creator of sway. As someone who is not involved in either project, I see two active projects, which offers more choice to users, makes it less likely for both projects to go away, offer competition and all around be in the spirit of open-source.
Often I hear, "if you don't like it, fork it" and then when it gets forked, you get called hostile? Doesn't make sense to me from a rational perspective - nobody forces you to adopt Gitea or Gogs if you don't want to.
Also, if you look at the release notes for both of them I think it's fairly easy to see that Gitea is developing at a much faster rate and has more features than Gogs already with a lot of nice features coming in 1.5.
However, I'm fairly biased, I used Gogs for a long time but switched as soon as Gitea popped up for the reasons above. Since then I've contributed a few fixes and features to Gitea as well.
- Issue due dates (https://github.com/go-gitea/gitea/pull/3794)
- Approval/comments on pull requests (https://github.com/go-gitea/gitea/pull/3748)
- Multiple assignees on issues (https://github.com/go-gitea/gitea/pull/3705)
- Dependencies for issues (https://github.com/go-gitea/gitea/pull/2531)
- CI status on pull requests (https://github.com/go-gitea/gitea/pull/2519)
Long story short: Gogs was slow in committing pull requests. The maintainer says it's because he has specific standards, the community sees it as just slowness. Anyway Gogs was forked into a new version that is supposed to be more active and well maintained.
Well the forking lit a fire under the ass of the Gogs maintainer and he has since become much more active than he was. For a month there there was reason to switch to Gitea as it was adding features that Gogs did not have at a rapid pace, but Gogs is now mostly caught up and there is reason to prefer it. I personally would go with Gogs. 1 passionate person > design by committee of people with shared low responsibility.
From gogs to gitea all metadata has been taken over (db was identical then). -- For gitea to gogs I read that the two projects have diverted. As I could afford to loose metadata of my not too many projects, I went back to gogs ditching and recreating everything (wrong switching decisions should be punished, don't they;).
If you're comfortable with Gogs you can stay though I do recommend to try out Gitea. IIRC from last time I compared, other than a few minor features they are mostly on part with Gogs.
The comments on that post suggest that Gitea is more actively developed, at least shortly after the fork, but I haven't checked to see if that's still the case.
If only other self-hosted/distributed projects were this easy to install. I skiped on discourse, mastodon, gitlab, etc. because they were all pain to setup on a base linux system.
Pleroma is a lot easier, though.
I'm not a fan of Go, but it does lead people into some right decisions, that Ruby and Python lead them away from.
Anyway, the problems start when you want to be sure it's running all the time your server is on, and on integrating it with your other web applications. Still, it's strictly better than interpreted environments.
If languages are making decisions for you, you aren't engineering software.
Beside that Gitea still got more really useful features compared to Gogs. But Gitea will always focus on Git hosting and won't bundle with CI, Chat and all that stuff what Gitlab does. There are enough tools you can easily connect to get features that Gitlab got, only if you need it.
It was a lot simpler than setting up a full blown Gitlab instance. It is just one binary to get running and that's it.
The 8 users are instantly familiar with the interface because of its similarity to GitHub.
We even have other users who are not contributors read the source through Gitea interface, rather than cloning the repos and reading locally.
It's a pleasant experience for small scale needs.
Maybe even some deeper integration with git itself, such as seeing new remotes on federated servers and fetching them.
This may sound redundant to GitHub, which currently centralizes everything, but different projects and companies have their reasons to not use a single external tool for this. As an example, CERN's Open Hardware Repository (https://www.ohwr.org/) would be a perfect fit for this, and other laboratories and companies could integrate with them.
Thanks for mentioning this here, I've been trying to raise this whenever I can, but not a lot of people seemed to care enough about this, hope this gets more visibility.
These issues and some others pop up if you search for federated.
There are tools like Gerrit and Phabricator. Also, projects like git and the linux kernel use mailing lists to handle things like issues, releases and pull requests/patch sets.
Definitely a great option for a GitHub alternative where you aren't looking for a feature-packed, i.e. large, deployment like Gitlab. It's simple and clearly delineated in its functionality.
However, it does suffer from a lack of good documentation - but I could just look at Gogs' documentation if needed since they're practically identical.
Everything including the website, documentation, blog, Hugo theme and so on is public available and also opensource.
It's a very pleasant and lightweight alternative to Github that I can only seriously recommend to anyone considering hosting their own Git Server. Recent update even brought mentions and reactions from Github over.
(Setup Github OAuth for easy onboarding)
What does this mean? Mentions as GitHub has it or that you can mention GitHub users in Gitea and vice-versa?
Although just seeing how trivial it was to deploy now I'm thinking about maybe running this in parallel at least. I still like being able to use CVS from ancient machines... But this does look nice. I guess time to look at cvs2git.
Then to visualize the contents you can try cgit (https://git.zx2c4.com/cgit/about/), I don't use it but it seems popular and is what kernel.org uses.
Your code is already public.
Just as I like having CVS, so I can take a stock Darwin 0.3 instance and sync code without having to spend a week plus trying to build the infrastructure to just talk to some external company who may either ban me or fold at any moment. If there is any kind of change I want, I can make it myself. It's called FREEDOM, which I'm always amazed that in the era or virtualization and cheap hosting so many would rather surrender the freedom to do their own thing.
I originally setup the CVSweb thing to let google crawl the pages, so instead of building a search service they would do it for me, which has worked surprisingly well. Although with all the other search engines around it does get a fair amount of traffic.
It strikes me as incredibly strange that we now have Linux and *BSD, this entire built up idea of taking power away from few hands like AT&T, or the various VAR's, moving away from Microsoft, and yet everyone is expected to throw everything they have into the hands of some other corporation to house their source code of all things... Having worked with http://www.oldlinux.org/ trying to hunt down 20 year old 'open source' projects which many have been lost, because of the same mistake of trusting 3rd parties who don't care, the amount of stuff that is going to be lost in the next 'I can't believe we are going to have another .com crash' is going to be incredible. And of course it'll seem like a trivial amount of space, just as something like 4.2BSD full source fits into 20MB, and yet could have easily been lost if it weren't for SIMH interest would have been completely lost.
I'm more impressed with sourceforge, as it's been around for quite some time, offers far more services than github, and survived their prior owners stupidity of trying to inject spyware into downloads.
Oh well, I guess that is my old man rant, don't rely on one thing, spread the software, don't let it sit on an apathetic 3rd party company who isn't even close to being able to operate without angel funding.
You would probably want to wrap it with nginx outside of docker-compose; attaching Certbot to it is thankfully very pleasant (https://www.digitalocean.com/community/tutorials/how-to-secu...).
To integrate with SendGrid, you'd set the app.ini (https://docs.gitea.io/en-us/config-cheat-sheet/) to point at SendGrid's SMTP relay (https://sendgrid.com/docs/API_Reference/SMTP_API/getting_sta...).
E.g. I add a label to my Gitea container to say "Serve this from git.mydomain.com", and Traefik will start redirecting requests and automatically configure a Let's Encrypt cert.
Basically you have all of your containers join the Docker network that your Traefik container is running on. Each container needs to expose a port (but not bind to the parent). The Traefik container will bind to port 80 on the parent. That guide should explain everything.
Let me know if you have any other questions or get stuck, I'd be happy to try and help!
I have been using it for about a year and recently put it on github, because I found it useful enough to share.
You an find it here https://github.com/chaosbunker/dockerbunker
Maybe not exactly what you are looking for, since I am not familiar with the discourse installer, but maybe interesting for someone? I’m happy about some feedback, since I never actively shared this until now.
Might look at switching to this though as it looks quite a bit more featureful but still simple to maintain
the admin wiki page is here http://wiki.osgeo.org/wiki/SAC:Gitea
Running gitbucket is simply "Java -jar gitbucket.jar"
JVM performance is pretty much world-class (and has been for many years). Golang and JVM compete neck to neck at top of the performance charts. Remember that startup performance is not what Java optimised for - it's long running processes like any web server or api.
And I'm far more excited by Graal than any programming language breakthrough over the past few years ( https://youtu.be/_7yIUkP5LiQ)
To me all of those things should be Git objects as well either tracked inside the same repo on another branch or something or tracked in a parallel Git repo.
We will see how well this works out, most required features are already there, the remaining will follow soonish.
I put it on a $5 VPS to host all my personal projects, works great. At the moment I ssh-port-forwarding to access its UI as I'm not sure how secure it is if exposed to the public directly.
The only feature I want to have now is something like : https://pages.github.com/, i.e. a static html site behind gitea login, so I can host all my project-related documents for easy access, not really a wiki fan as wiki is painful to navigate sometimes.
However I prefer to put stuff on Github because it's the go to place for OSS projects right now. If you are publicly releasing a project, it's with the hope it will be actually useful to other people, putting it on Github increases the visibility of said project and the likelihood of it being useful to other people.
Different strokes for different folks. I usually fill the fingers on one hand counting the folks reaching out each week. Rarely are they interesting (like a lot of my stuff on GitHub) positions, but still tons of unsolicited offers.
According to https://gitea.io/en-US/:
> It’s all on GitHub
accompanied by an invitation to join the development there.
But nobody in the team wants to do the switch if not all features are available that we rely on today at github.
So, what does this give me over using the main Gogs? I see it is managed differently, but what features does it offer that are not in Gogs?
You say that like it's a bad thing.
Let's break it down:
> The owner of the Gogs repo doesn't accept pull requests that won't fit his roadmap
That generally sounds bad. Like, in an ideal world, you would be open to changing your roadmap. Specifically the timing, for sure. Also, you would be open to accommodating features you hadn't thought of, etc.
So, this sounds like a negative, basically.
> or quality standards,
Starting with a negative, continuing with just an "or" makes it sound like you're about to list another negative.
I'd expect a "but" or a "but thankfully," or something.
> he is also not the most responsive during times this
This is absolutely a negative.
He doesn't bad thing, or xxx, he is also bad thing.
Reading that sentence structure makes "xxx" sound like another bad thing.
Gogs: https://github.com/gogits/gogs/graphs/contributors
Gitea: https://github.com/go-gitea/gitea/graphs/contributors
(switch from one tab to the next to see the difference)
GitHub is free for public repositories and has huge engineering teams dedicated to uptime, security, and availability.
At the very least for Gitea/Gogs to self-host the code they'd have to pay for hosting costs that GitHub is already willing to provide for free.
https://about.gitlab.com/better-than-github/ ; https://github.com/WebEntity/Installation-guide-for-GitLab-o... ; https://github.com/gitlabhq/gitlabhq/blob/8-0-stable/doc/ins... ; https://about.gitlab.com/downloads/
It's basically most of the features of GitHub; if you want the rest of GitLab's features you'll have to set them up yourself.
Still, it's hard to beat free and lightweight.
Besides that it is a lot less resource hungry.
Ok, of course I'm opinionated as a Drone plugins maintainer and former Gitea owner :P
Most compilers I'm aware of gets compiled by themselves. I think it's great for two things:
1) Show how serious the compiler is - compiler code tends to be complicated 2) Free real life testing
I was expecting Gitea to be hosted on Gitea for the same reasons. Was trying to offer criticism but got downvoted immediately, ahh HN =)
- uses less resources, a 512MB VM is enough for a small team. Meanwhile Gitlab requires at least 4GB IIRC. - is easier to setup, just a single binary file.
Everything else, it can't compete with Gitlab.
I'm using it as my personal Git server, works pefectly for 1 user.
Gogs is able to sync an external git repo every 12 or 24 hours.
That way, if one day, Github goes belly-up, even if it's unlikely in the foreseeable future, I would have a backup plan.
I also use it for personal and not public projects (automation scripts, secrets, etc).
:-}