π Pipeline Overview
The pipeline is triggered automatically on every push to the repository.
It contains the following stages:
Code β Initial stage
Lint Check β Code quality checks
Build β Build or compile the project
Testing β Run automated tests
Deploy β Deploy to an environment
Release β Final release stage
Each stage runs only after the previous stage is completed using the needs: dependency.
π CI/CD Stage Flow
This workflow follows a strict sequential order:
Code β Lint Check β Build β Testing β Deploy β Release The needs: keyword ensures that each job runs only after the previous stage completes successfully.
π Key Features
β Fully automated pipeline β Sequential stage execution β Simple and easy to understand β Good base template for real-world CI/CD workflows β Uses Ubuntu GitHub-hosted runners
π How to Use
Create the folder:
.github/workflows/
Create a file inside it, for example:
cicd-demo.yml
Paste the workflow code.
Commit and push the file β the pipeline will start automatically.