Learn GITLAB-CI with Real Code Examples
Updated Nov 27, 2025
Code Sample Descriptions
1
Simple GitLab CI Pipeline
# .gitlab-ci.yml
stages:
- build
- test
build_job:
stage: build
image: node:16
script:
- npm install
- npm run build
tags:
- docker-runner
tags:
- docker-runner
test_job:
stage: test
image: node:16
script:
- npm install
- npm test
tags:
- docker-runner
A simple GitLab CI pipeline to build and test a Node.js application.