GitLab CI
GitLab's built-in CI/CD. .gitlab-ci.yml in the repo root. The native choice if you're on GitLab.
Mindmap
The plain-English version
GitLab CI is GitLab's pipeline runner, configured by a .gitlab-ci.yml file at the repo root. Self-hosted GitLab or gitlab.com both work. Pipeline runs on GitLab-managed runners or self-hosted runners. Tight integration with GitLab's merge requests, environments, and registry.
The problem it solves
If your repo is on GitLab, GitLab CI is the path of least friction. The DSL is YAML like Actions but with GitLab-specific concepts (stages, environments, includes). Strong story for self-hosting (a lot of regulated industries use self-hosted GitLab end-to-end).
Alternatives
| Alternative | Type | When it wins |
|---|---|---|
| GitHub Actions | CI/CD | GitHub's built-in CI/CD. YAML in your repo. Free for public, generous for private. The default for anything on GitHub. |
| Jenkins | CI/CD | The CI/CD elder. Self-hosted, plugin-driven, dominant in enterprise. The Groovy Jenkinsfile is a rite of passage. |
Deep links
The words you'll hear
- Stage
- A phase of the pipeline (build, test, deploy). Jobs in the same stage run in parallel.
- Job
- A unit of work.
- Runner
- A machine that picks up and executes jobs. Shared (GitLab.com) or self-hosted.
- Environment
- A named target (staging, production). Tracks deployments per branch.
- Include
- Pull config from another file or repo. Reusable templates.
- Cache / Artifacts
- Cache reuses content across jobs/runs; artifacts publish output.
Bad vs. good prompt for GitLab CI
Why it works: Specifies the stage layout, caching pattern, deployment gating, and image. Maps cleanly to GitLab idioms (stages, environments, manual triggers).
What bites real teams
Self-hosted runners drift from .gitlab-ci.yml expectations (different OS, missing tools). Pin to specific images where possible.
GitLab.com free tier minutes are tighter than GitHub's. For heavy projects, self-host runners or pay.
A job's stage: tells when it runs; the top-level stages: defines the order. Both are needed; both confuse first-timers.