Typical pipeline stages
- Source: developer pushes code to Git.
- Build: pipeline compiles or packages the application.
- Test: automated unit and integration tests run.
- Quality and security: static analysis and dependency or image scanning run.
- Artifact: a versioned package or container image is published.
- Deploy: the artifact is promoted to a target environment.
- Observe: logs, metrics and alerts help validate application health.
Example flow
Git push
-> Build
-> Unit tests
-> SonarQube quality gate
-> Trivy image scan
-> Publish image
-> Approval
-> Deploy to KubernetesCI versus CD
Continuous Integration (CI) frequently integrates and validates code changes. Continuous Delivery keeps changes deployable with controlled release decisions. Continuous Deployment automatically releases qualifying changes to production.
Good pipeline practices
- Keep credentials in a secret manager, not source code.
- Use immutable, traceable artifact tags.
- Fail safely when critical quality or security gates fail.
- Separate build from deployment and promote the same artifact.
- Use approvals and rollback strategies appropriate to production risk.
Practice task
Draw a pipeline for a simple Node.js website. Identify where you would run tests, scan dependencies, build a Docker image and deploy to a test environment.
Continue learning
Explore more practical DevOps and cloud tutorials in the Devops Init learning hub.
Back to learning hub →