# AZ-400 Practice - week 3: Complete Blue/Green + Canary CI/CD on AKS

I started this side project 3 weeks ago and built a production-grade deployment pipeline for [demourlisd.one](http://demourlisd.one/) that demonstrates all major AZ-400 concepts in one flow:

- Infrastructure Pipeline: Terraform state storage + AKS + LoadBalance provisioning
- Deployment Pipeline: Deploys full service stack (API + LLM Adapter + Ollama/phi3:mini) to both blue AND green environments + updates Cloudflare
- Release Pipeline: Traefik traffic switching: Blue↔Green toggle OR Canary percentage (no redeploys!)
- Teardown Pipeline: Deletes the Azure resources + resets DNS/KV (back to $0 hosting)
- End-to-end HTTPS: Cloudflare Full SSL → Traefik Let's Encrypt

Pipeline execution times:

- Infrastructure: 16 min (cluster + nodepool + storage)
- Deploy → fresh: 9 min (Traefik + app)
- Deploy → app-only: 4 min (subsequent deploys)
- Release → blue/green percentage: seconds
- Teardown: ~15 minutes

The same deploy pipeline is used to deploy to dev-blue and dev-green. When done, I tear it down to save costs.

![AZ-400 DevOps demo pipeline overview diagram](https://images.koorevaar.com/linkedin-import/az400-week3-blue-green-canary-aks.jpg)

---

*Co-authored with Claude.*

If this was useful, [you can buy me a coffee](https://ko-fi.com/p47k0).

New articles: [follow via RSS](https://blog.koorevaar.com/feed.xml).
