CI/CD: from "it worked on my machine" to automated deployment
Published on 2025-11-14
A Simple Guide for Beginners: Jenkins → GitLab → GitHub → GitOps
Hello!
Are you just starting your DevOps journey or tired of hearing “and we use CI/CD” in interviews? Want to finally understand why code that works on your laptop fails on the server?
This article is your first step toward automation. And it will really be easy.
We’ll break everything down, without overloaded terms and with examples.
What is CI/CD (very simple)
CI/CD is when you press
git pushand everything else happens automatically.
Let’s break it down:
| Abbreviation | What it means | Why it’s needed |
|---|---|---|
| CI (Continuous Integration) | Continuous integration | So code from different developers doesn’t break each other |
| CD (Continuous Delivery / Deployment) | Continuous delivery | So updates can be rolled out with one button — or without a button at all |
Real-life example
You and a friend are building a website.
- Without CI: on Friday you try to merge code → hundreds of errors → goodbye weekend.
- With CI: every
git pushtriggers tests → errors are visible immediately.
Tools: from “grandfather” to “trendy”
Jenkins — “the grandfather of CI/CD”
Jenkins is like an old but powerful industrial machine. You can make it do almost anything, but you’ll have to learn to live with it.
How it works
- You install Jenkins on a server
- You write instructions in a
Jenkinsfile - Jenkins watches Git and runs pipelines
Pros
- Maximum flexibility
- Thousands of plugins
Cons
- Maintenance, updates, and operations are on you
- The interface hasn’t changed in many years
For whom
Large companies or projects with historical baggage.
GitLab CI/CD — “all-in-one”
GitLab is not just a GitHub replacement. It’s a whole DevOps suite: CI/CD, Registry, monitoring, security.
How to get started in 5 minutes
- Create a repository
- Add the file
.gitlab-ci.yml:
stages:
- test
- build
test:
stage: test
script:
- echo "Запускаю тесты..."
build:
stage: build
script:
- echo "Собираю Docker-образ..."
- Do a
git push— and the pipeline will start automatically.
Pros
- Nothing to deploy
- Everything in one dashboard: code → build → container → deploy
- Generous free CI minutes
Cons
- If the team is already on GitHub, migration can be difficult
For whom Teams that need everything out of the box.
GitHub Actions — CI/CD right inside GitHub
Have your code on GitHub? Then CI/CD is already waiting for you.
Create the folder .github/workflows/.
Example: run tests on every push
name: Тесты
on: [push]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Запуск тестов
run: echo "Тут мог бы быть pytest"
Pros
- Marketplace with a huge number of ready-made actions
- Free for public repositories
- Easy integration with clouds and services
Cons
- Minute limits for private repositories
For whom For everyone already using GitHub. The de-facto standard.
Runner — who runs the jobs
A pipeline is a recipe.
A runner is the chef who cooks from the recipe.
| Platform | Types of Runners |
|---|---|
| GitLab | Shared and Self-hosted |
| GitHub | Hosted (GitHub VMs) and Self-hosted |
GitOps — the “Pro” level
GitOps is an approach where Git is the single source of truth.
Simple principle
- You change YAML in Git → the cluster updates automatically
- Manual
kubectl apply→ considered bad practice
Why it’s powerful
- Configurations are reproducible
- Logs and change history are always available
- The server always reflects the “state from Git”
GitOps tools
| Tool | Description |
|---|---|
| Argo CD | A pretty dashboard. You can see Desired and Actual state. |
| Flux CD | Minimalist. Everything is managed via Git, almost no UI. |
Which tool to choose
| Situation | Choice |
|---|---|
| You store code on GitHub | GitHub Actions |
| You want everything in one place | GitLab CI |
| Complex historical infrastructure | Jenkins |
| Kubernetes + automation | GitHub/GitLab + Argo/Flux |
Set up your first pipeline (5 minutes)
- Create a private repository on GitHub
- Add the file
.github/workflows/ci.yml:
name: CI
on: [push]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: echo "Привет, CI/CD! 👋"
- run: echo "Тесты пройдены ✅"
- Do a
git pushand open the Actions tab
Done — your first CI/CD is working.
Useful tips
- Start simple:
build → test. - Don’t store passwords in the repository — use Secrets.
- Run deployments only from the
mainbranch. - Pipelines should be short and clear.
Conclusion
You have already taken the first step.
Today — simple CI.
In a week — running tests.
In a month — building Docker images.
In six months — GitOps and automatic deployments.
CI/CD is not magic. It’s just automation of your usual development steps.
And you can definitely do it.
Related reviews
Very pleased with working with Mikhail. Any task, even one that seems difficult at first, is executed to a high standard thanks to him! Thank you )
Dr-zelenin · VPS setup, server setup
2025-11-11 · ⭐ 5/5
Very satisfied with working with Mikhail. Any task, even one that seems difficult at first glance, becomes, thanks to him, implemented to a high standard! Thank you)
Thanks to Mikhail for his professionalism. I recommend him. He was very helpful in helping me understand Docker.
Vadim_U · VPS setup, server setup
A customer who has settled in2025-11-10 · ⭐ 5/5
Thanks to Mikhail for his professionalism. I recommend him. He was a great help in getting to grips with Docker.
Mikhail is an expert. He quickly figured it out and fixed the problem.
Vadim_U · VPS setup, server setup
An acclimated customer2025-11-10 · ⭐ 5/5
Mikhail is an expert. Quickly figured it out and resolved the issue.
Comes through for any problem — I recommend it!
AlekseiDotsenko · VPS setup, server setup
Power buyer2025-11-05 · ⭐ 5/5
Comes to the rescue with any problems, I recommend!
Mikhail helped set up the website very quickly. I would’ve definitely been fiddling with it all day. It’s great when a professional saves your time and delivers high-quality work. I recommend him!
N_Konstantin · VPS setup, server setup
An established customer2025-10-21 · ⭐ 5/5
Mikhail was very prompt in helping set up the website. I would definitely have been tinkering with it all day. It's nice when a professional helps save your time and does the work at a high level. I recommend him!
The most qualified, top-notch specialist who knows his stuff.
Alexeyvodopyanov · VPS setup, server setup
Experienced buyer2025-10-21 · ⭐ 5/5
The most qualified and coolest specialist who knows their stuff