🚀 Built a fully automated CI/CD pipeline — from code to cloud in under 3 minutes. I've been on a self-learning journey into DevOps, and this week I wanted to stop reading about CI/CD and actually build one. Here's what happens the moment I run git push: ✅ GitHub Actions spins up a fresh Ubuntu VM ✅ 4 automated pytest tests run — if any fail, everything stops ✅ A Docker image is built and pushed to Docker Hub (tagged with the commit SHA for traceability) ✅ The container is deployed live to AWS EC2 via SSH ✅ The old version is replaced with zero manual steps Total time: ~2 minutes. Human involvement after the push: zero. What I learned building this: → The needs: keyword in GitHub Actions creates a real safety chain — broken code physically cannot reach production → Secrets management isn't optional — credentials belong in encrypted GitHub Secrets, never in code → Docker layer caching (copying requirements.txt before your app code) can cut build time significantly → Tagging images with github.sha means every deployment is traceable to its exact commit — rollback in under 60 seconds Tech stack: Python · Flask · Docker · GitHub Actions · AWS EC2 · pytest Live API: http://13.61.177.113:5000 The biggest lesson? Automation isn't about replacing effort — it's about making effort reliable. #DevOps #CICD #Docker #AWS #GitHubActions #CloudComputing #LearningInPublic #Python

To view or add a comment, sign in

Explore content categories