Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Ask HN: Gitlab or Gitea for self-hosting Git?
15 points by warrenm on Sept 15, 2023 | hide | past | favorite | 22 comments
Use case needs:

- internal, small company (<10 "devs" of any kind) development source control

- as lightweight as possible (but no lighter)

- support for "common" git clients (vscode, cli, atom, etc)

If it matters, most of the development work that will be going on is related to config file management, xml documents, scripts, etc - for the foreseeable future, we have no need for integrations into automated build systems

With those needs/conditions in mind, would you pick Gitea, Gitlab, or something else ... and why?



Go with Gogs.

Just makes sure you _really need_ to host your own git repo and it's not some sort of overzealous security/compliance measure. If you don't trust github, gitlab, maybe sourcehut (https://sr.ht - no affiliation) is a good fit?

If you do setup an internal repo, makes sure you setup mirrors and/or remote backups and a documented and tested disaster recovery scenario.

ps. if you don't need a web interface, a UNIX server running SSH is just fine. Server side:

    $ mkdir -p Projects/myeliteproject.git && cd 
    Projects/myeliteproject.git
    $ git init --bare
    $ exit
On the dev machine:

    $ mkdir -p Projects/myeliteproject.git && cd Projects/myeliteproject.git
    $ git init
    $ git remote add origin ssh://[user]@[hostname]/full/path/to/the/repo.git
    $ git push origin master
    $ echo "We need this commit in order to avoid errors" > first_commit.txt
    $ git add first_commit.txt
    $ git commit
    (write a reason here... "first needed commit" is a good one)
    $ git push
    $ git config branch.master.merge 'refs/heads/master'
    $ git config branch.master.remote origin
    $ git config --global push.default current
    (<em>This config is to avoid warning messages. Please read <a href="http://progit.org/book/ch9- 
    5.html">here</a> and consult documentation for refspecs</em>)
    $ git pull

    Already up-to-date.
And if you need a web interface: https://git-scm.com/book/en/v2/Git-on-the-Server-GitWeb :-)


I set up Gogs for the company I work for, and I'd recommend against using it in production. The initial setup was easy, but it's slow, buggy, and difficult to manage.


There's also the gitea fork https://forgejo.org/ to consider if the reasons for the fork (FAQ) speak to you.

Now I don't think this is a good idea, but since you specifically said as lightweight as possible I just wanted to mention it-

Running just git on an ssh accesible user is absolutely the most lightweight possible solution. You just need git and ssh, that's it. It's compatible with every normal git client, and does all the normal git stuff. This is how I manage my smaller personal projects (running on a raspberry pi), and it works fine for a single person.

There's no CI/CD. No Pull Requests, no web GUI, none of the niceties of any of the options mentioned here.

However if it's really very lightly used, and by technically inclined people, it may be an option.

e: I stand corrected, there is apparently a web UI!


For my personal website I had the same question. I chose Gitea because it has a simpler stack than Gitlab can't say much more than that. Gitea will work for your use case.

Consider looking at the financial cost of support for both. As a company your time fixing problems is what I think is the most important consideration. Initial setup time is a small price compared to lifelong maintenance.

For Gitea I never had any problems I didn't create myself. But aren't all problems like that. And I didn't have a very complicated set up.


Either one some of us (beginning with me) will have to learn to support

So...not sure there's a big difference on that front :)


For a small company with your needs, I would recommend Gitea. It is a lightweight, self-hosted Git server that is easy to set up and manage. It also supports all of the common Git clients, including VSCode, the CLI, and Atom.

Gitea is a good choice for small companies because it is lightweight and easy to use. It also has all of the features that you need for basic source control management.

However, if you need integrations with automated build systems, then GitLab is a better choice. GitLab is a more powerful and feature-rich Git server, but it is also more complex to set up and manage.

Ultimately, the best choice for you will depend on your specific needs and requirements. If you are looking for a lightweight and easy-to-use Git server, then Gitea is a good option. If you need integrations with automated build systems, then GitLab is a better choice.


if you need CI/CD gitlab. if you allready have CI/CD with something like jenkins or whatever, or even if you dont need CI/CD at all gitea.


No CI/CD


Gitlab. The company could grow, and you'll need more features, and you'll likely lack time/energy/resources to deal with admin stuff like source control. Gitlab self-hosted is mostly painless to manage - the default installers just work as long as you have an instance dedicated to it, and on a day to day level it is not at all burdensome to operate.

Another key point is: software is not just software. Your team will develop habits and working style. It'll be dead investment if you have to change software at a later time.


Gitlab is a terrible piece of software engineering. Avoid it if you can afford it.


There’s also https://onedev.io/ which deserves a mention. I’ve never personally used it but it looks promising.


You could use a linux server with a bare repo as remote like atmosx said. And if you want a web interface just do:

> git instaweb

https://git-scm.com/book/en/v2/Git-on-the-Server-GitWeb


I did use https://gogs.io/ in the past. Was nice.

Not in the same league. But might be adequate for OP.


Isn’t Gitea a fork of Gogs?


More features. Gogs is just git hosting.


This isn't an answer, rather a wish. Since forgefed (git collaboration over activitypub) is coming up, I'm hoping for something lightweight and self-hostable. Cgit UI is nice. No need for namespaces - it doesn't make sense for projects and individuals that self-host. Access control should be similar to what gitolite offers. (Basically Cgit + gitolite + forgefed + email - preferably single binary).


Gitea is significantly easier to set up and maintain


I've been hosting, maintaining and upgrading gitea for more than a year so far meanwhile at work I've been using the company's Gitlab instance.

In general they work fine but Gitlab had many times upgrade issues resulting in downtimes more often than not. And Gitea resources use feels more light in general.


I'm pretty happy with Gitea, does the job, simple to set up and now it support actions with multiple runners.

Tried gitlab, was a nightmare to set up and consumed a lot of resources.


I've been running Gitlab CE for a year now. I pay about 20 US a month for the box... Setup was not bad, upgrading is, but still manageable. The benefit is massive, in comparison with Gogs or Gitea. Gitlab is a much more robust product.


Gitea is lighter, GitLab has more features. Look at the Gitea features list and see if it works for you.

Obviously both are Git hosting platforms so I'm not sure what more we can do for you.


Gitea, as someone using GitLab. Both will intefrate with editors though GitLab's MR/ Issues tend to have more mature integrations (if you want that in your editor).

GitLab is good for teams or when you want to play with a fully featured CI/CD and have a solid Issue/ MR System. It however is also quite a hassle to maintain sometimes though the omnibus installations have gone a long way. Also be prepared to spare some RAM.

Gitea on the other hand is light and comes with some QoL things like non-paywalled Repository mirroring and compatibility with GitHubs CI. It's also a bit snappier and very easy to run. The ressource usage also reflects this both from disk space and RAM.

It's kinda like comparing vscode to a full blown IDE.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: