This tutorial is a complete, real-world guide to building a production-ready CI/CD pipeline using Jenkins, Docker Compose, and Traefik on a single Linux server.
You’ll learn how to expose services on a custom domain with auto-renewing HTTPS, and implement a smart deployment strategy that detects changes and redeploys only the affected microservices. This helps avoid unnecessary full-stack redeploys. We'll also cover real production issues and the exact fixes for each one.
Table of Contents
1. What you'll build
2. Architecture
3. Server prerequisites
4. Traefik — the reverse proxy
5. Run Jenkins in Docker
6. Expose Jenkins on a domain via Traefik
7. First-time Jenkins setup
8. Add the GitHub credential
9. Create the pipeline job
10. The Jenkinsfile (deploy only what changed)
11. End-to-end test
12. Troubleshooting — every error we hit
13. Mental model: host vs. container
14. Daily operations cheat sheet
15. What I'd do differently next time
Closing thoughts
1.…