我喜欢GitLab
I Like GitLab

原始链接: https://www.whileforloop.com/en/blog/2026/01/21/i-like-gitlab/

多年来,作者一直依赖 GitLab 用于私有项目,最初是被其提供免费私有仓库,而 GitHub 当时需要付费所吸引。尽管 GitHub 现在也提供免费私有仓库,但作者的工作流程已在 GitLab 生态系统中稳固建立。 一个关键优势是 GitLab 集成的容器注册表,提供了一个简单、私有的 Docker 镜像存储解决方案,无需 Docker Hub 的复杂性。通过 `.gitlab-ci.yml` 配置的 GitLab CI/CD,提供了用于构建、推送和部署镜像的版本化流水线,并利用共享运行器实现经济高效的自动化。 作者承认 GitLab 偶尔会出现迟缓和功能过载的问题——提供了超出核心需求的大量工具,但仍然认为其价值主张很有吸引力。免费托管大约一打私有项目,并拥有强大的 CI/CD 和容器注册表功能,使 GitLab 成为实验和开发的理想“数字工坊”。 作者策略性地使用 GitHub 用于公共项目,在协作、可见的工作与 GitLab 中的私有、探索性开发之间保持清晰的区分。

## Hacker News 上关于 GitLab 与 Forgejo 的讨论 一篇 Hacker News 讨论强调了一位用户从自托管 GitLab 切换到 Forgejo 的积极体验。虽然承认 GitLab 功能强大且仍在工作中继续使用,但该用户发现 Forgejo 在个人项目上速度更快,资源消耗更少,并指出 GitLab 中未使用的功能证明了切换的合理性。 评论者们对此表示认同,赞赏 Forgejo 的性能优势。一位用户特别看重 GitLab 可自托管的 AI 功能(Duo),以及使用个人 OpenAI/Anthropic 密钥的选项。另一位用户赞扬了避免 GitHub Actions 的问题,并指出 GitLab 最近转向单页应用程序 (SPA) 已经提高了其速度。总的来说,对话表明 Forgejo 对于优先考虑速度和效率而非广泛功能的用戶来说是一个有吸引力的替代方案。
相关文章

原文

I’ve been using GitLab for my private projects for years now. I just started using it at some point and never had a reason to switch.

How I ended up here

Back when GitHub still charged for private repositories, GitLab offered them for free. That was the initial hook. I had a bunch of small projects and experiments that I didn’t want to publish but also didn’t want to pay for. GitLab was the obvious choice.

GitHub eventually made private repos free too, but by then my workflow was already built around GitLab. All my CI pipelines, Docker images, deployment scripts - everything pointed there.

The Docker registry thing

Every GitLab project comes with a Container Registry. This is probably the feature I use most.

The workflow is simple. Build an image locally or in CI, push it to the registry, pull it wherever you need it.

No separate Docker Hub account. No thinking about pull rate limits (remember when Docker Hub introduced those and broke half the internet’s CI pipelines?). No managing access tokens for yet another service.

For my private projects this is perfect. I don’t need the discoverability of Docker Hub. I just need a place to store images that integrates with my existing authentication.

The 10GB limit per project sounds small on paper but I’ve never come close to hitting it. Old tags get cleaned up, base layers are shared, and most of my images aren’t that big anyway.

CI/CD

GitLab CI was one of the earlier “CI config as code” implementations that I used. You drop a .gitlab-ci.yml in your repo and things start happening. The config is versioned with everything else, which means you can see exactly what your pipeline looked like six months ago.

Nothing fancy. Build the image, push it, optionally deploy. The manual trigger on deploy is nice - I can build automatically but still control when things go to production.

The shared runners GitLab provides handle most of my workloads. They’re not fast, but they’re free and reliable. For the times when I needed something specific - like a runner with more memory or access to my private network - setting up my own runner on a cheap VPS was straightforward. Install the runner, register it with a token, done.

The documentation for CI/CD is extensive. Almost too extensive. There are so many features and options that finding what you need can take a while. But once you figure out your patterns, you mostly copy-paste from your own previous configs.

The annoying parts

Let’s talk about what’s not great.

Speed. The GitLab web interface has always felt sluggish to me. Click on a merge request, wait. Switch to the pipeline view, wait. Open the job log, wait. It’s not terrible, but there’s this constant friction that adds up over a long session.

I’ve noticed improvements recently. Either they optimized things or I’ve just gotten used to it - hard to say. But it’s still not as snappy as GitHub.

Feature overload. GitLab tries to be everything. Issue tracking, project management, wiki, snippets, package registry, container registry, security scanning, infrastructure management, monitoring… The sidebar menu goes on forever.

I use maybe 10% of what’s available. Repositories, merge requests, CI/CD, container registry. That’s pretty much it.

This is a double-edged sword. On one hand, feature bloat. On the other, if I ever need something like a private NPM registry or security scanning, it’s already there. I just haven’t needed it yet.

The value proposition

I run about a dozen private projects ranging from active side projects to abandoned experiments I keep around “just in case.” None of this costs me anything. It’s crazy.

My workflow

All my private projects live on GitLab. Prototypes, experiments, half-finished ideas, things I’m actively working on but not ready to share. It’s my digital workshop where I can make a mess without anyone watching.

GitHub is different. That’s where I put things I want people to see.

This split works well for me. I get the collaboration and visibility benefits of GitHub for public stuff while keeping my private mess organized on GitLab with proper CI/CD and container registries.

Some people do everything on GitHub. Some do everything on GitLab. Having a foot in both camps might seem redundant but honestly, they serve different purposes in my workflow.

联系我们 contact @ memedata.com