GitLab CI/CD Interview Questions
10 questions
GitLab CI/CD interview questions on pipeline stages, runners, and the caching and artifact decisions that determine whether a pipeline is fast or fragile.
A teammate used 'cache' to pass compiled build output from the build job to the deploy job, and it intermittently fails to find the files. What did they get wrong?
IntermediateGitLab CI/CD6 min
You have a monorepo where a single commit might touch 1 service or 15. How would you use GitLab's dynamic child pipelines so you only run CI for the services that actually changed?
AdvancedGitLab CI/CD8 min
A shared library lives in its own GitLab project, consumed by 5 downstream application projects. How would you trigger those downstream pipelines automatically when the library changes?
IntermediateGitLab CI/CD6 min
Your GitLab pipeline runs 6 stages sequentially, but half your jobs don't actually depend on each other. How would you use 'needs' to speed this up?
IntermediateGitLab CI/CD6 min
How do you make sure a production deployment token stored as a CI/CD variable can only ever be used by pipelines running against your main branch, not a random feature branch?
IntermediateGitLab CI/CD6 min
A new job you added to .gitlab-ci.yml is stuck 'pending' forever and never picked up by any runner. What's the most likely cause, and how do you fix it?
BeginnerGitLab CI/CD5 min
What's the difference between a branch pipeline and a merge request pipeline in GitLab CI, and why does it matter which one actually runs for a given push?
IntermediateGitLab CI/CD7 min
What debugging challenge does a GitLab merged results pipeline introduce that a plain branch pipeline doesn't, when a job fails?
IntermediateGitLab CI/CD6 min
How would you write .gitlab-ci.yml rules to prevent duplicate pipelines from firing for both a branch push and its merge request?
IntermediateGitLab CI/CD6 min
How does GitLab's pipeline trigger distinction compare to GitHub Actions' push vs pull_request trigger?
IntermediateGitLab CI/CDGitHub Actions6 min