A comprehensive DevOps pipeline demonstrating CI/CD automation, container orchestration, infrastructure-as-code, and monitoring — deployed on AWS EKS.
Note: Badges will show live status after the first workflow run on the
mainbranch.
Features • Architecture • Getting Started • Project Structure • API • Infrastructure • Monitoring
| Area | Capabilities |
|---|---|
| CI/CD | GitHub Actions with multi-stage pipeline: lint → test → build → security scan → deploy |
| Containerization | Multi-stage Docker builds with security hardening (non-root user, read-only filesystem) |
| Orchestration | Kubernetes with HPA auto-scaling, rolling updates, resource limits, and ingress with TLS |
| Infrastructure-as-Code | Terraform provisioning of VPC, subnets, NAT Gateway, EKS cluster, and node groups |
| Security | Trivy container vulnerability scanning, Pod Security Context, non-root execution |
| Observability | Prometheus metrics collection and Grafana dashboards with custom application metrics |
| High Availability | Multi-AZ deployment, auto-scaling (3–10 pods), health checks with liveness/readiness probes |
flowchart TB
subgraph Developer["Developer Workflow"]
A[Git Push] --> B[GitHub Actions]
end
subgraph CI_CD["CI/CD Pipeline"]
B --> C[Lint & Test]
C --> D[Docker Build & Push to GHCR]
D --> E[Trivy Security Scan]
E --> F[Deploy to Kubernetes]
end
subgraph AWS["AWS Cloud (us-east-1)"]
subgraph VPC["VPC 10.0.0.0/16"]
direction TB
IG[Internet Gateway]
NAT[NAT Gateway]
subgraph Public["Public Subnets (AZ a + b)"]
ALB[Application Load Balancer]
end
subgraph Private["Private Subnets (AZ a + b)"]
EKS[EKS Cluster]
subgraph K8S["Kubernetes"]
Pods[Application Pods
Replicas: 3-10]
HPA[Horizontal Pod
Autoscaler]
end
end
end
ECR[ECR Container Registry]
end
subgraph Monitoring["Monitoring Stack"]
Prom[Prometheus
Scrape Interval: 5s]
Graf[Grafana
Dashboards]
end
F --> K8S
D --> ECR
ECR --> EKS
IG --> ALB
ALB --> Pods
Prom --> Pods
Graf --> Prom
style Developer fill:#e1f5fe,stroke:#01579b
style CI_CD fill:#f3e5f5,stroke:#7b1fa2
style AWS fill:#fff3e0,stroke:#e65100
style Monitoring fill:#e8f5e9,stroke:#1b5e20
| Category | Technologies |
|---|---|
| Application | Node.js (v18), Express.js |
| Containerization | Docker, Docker Compose, GitHub Container Registry (GHCR) |
| Orchestration | Kubernetes v1.29, HorizontalPodAutoscaler, Ingress NGINX |
| Infrastructure | Terraform ≥1.3.0, AWS (EKS, VPC, EC2, IAM, S3, DynamoDB) |
| CI/CD | GitHub Actions, Trivy Security Scanner |
| Monitoring | Prometheus, Grafana, prom-client (custom Node.js metrics) |
| Testing | Jest, Supertest, ESLint |
- Node.js v18+
- Docker & Docker Compose
- kubectl configured for your cluster
- Terraform ≥1.3.0
- AWS CLI configured with appropriate credentials
- For Terraform backend: Create S3 bucket
devops-portfolio-terraform-statein your AWS account
# Install dependencies and run tests
cd src
npm install
npm test
# Run the application locally
npm startThe API will be available at http://localhost:3000.
# Start all services (app + Prometheus + Grafana)
docker compose up -d
# Services:
# - App: http://localhost:3000
# - Grafana: http://localhost:3030 (admin/admin)
# - Prometheus: http://localhost:9090
# Stop everything
docker compose downNote: Update the ingress domain from
app.example.comto your real domain ink8s/deployment.ymlbefore deploying to production.
# Deploy to your cluster
make deploy-k8s
# Or manually:
kubectl apply -f k8s/namespace.yml
kubectl apply -f k8s/configmap.yml
kubectl apply -f k8s/deployment.ymlPrerequisite: Create the S3 bucket
devops-portfolio-terraform-statefor the Terraform backend before runningterraform init.
cd terraform
# Initialize and review
export AWS_REGION=us-east-1
terraform init
terraform plan
# Apply infrastructure
terraform apply -auto-approve
# Configure kubectl
aws eks update-kubeconfig --region us-east-1 --name devops-portfolio-cluster
# Destroy when done
terraform destroy -auto-approvedevops-portfolio-project/
├── .github/
│ └── workflows/
│ └── ci-cd.yml # CI/CD pipeline (5 stages)
├── k8s/ # Kubernetes manifests
│ ├── namespace.yml # Namespaces: production, staging, monitoring
│ ├── configmap.yml # App ConfigMap + Secrets
│ └── deployment.yml # Deployment, Service, Ingress, HPA
├── monitoring/ # Observability stack
│ ├── prometheus.yml # Prometheus scrape config
│ └── grafana-dashboard.json # Pre-configured Grafana dashboard
├── terraform/ # Infrastructure-as-Code
│ ├── main.tf # Provider & VPC setup
│ ├── networking.tf # Subnets, routes, NAT Gateway
│ ├── eks.tf # EKS cluster & node group
│ ├── variables.tf # Configurable variables
│ └── outputs.tf # Terraform outputs
├── src/ # Application source code
│ ├── app.js # Express.js API (health, users, metrics)
│ ├── app.test.js # Jest + Supertest test suite
│ ├── package.json # Node.js depen