Don't Manage Your Infrastructure Twice: The Terraform + Ansible Collaboration Boundary and 5 Production-Grade Decisions

Overview 2 AM, the alert channel exploded. A web server that went live two hours ago was at 100% CPU. SSH in — Nginx wasn’t installed, but an old Apache was squatting on port 80. Checked the deploy logs: Terraform had run terraform apply ten minutes ago, rebuilding the machine (someone changed instance_type), but Ansible’s configuration playbook never followed — fresh machine, all software configs gone. This isn’t an isolated incident....

September 5, 2026 · 22 mins · 4651 words · ABao

Ansible Playbook Best Practices: From Basics to Production

Overview Ansible has a low barrier to entry — a YAML file and a few lines of yum install can get things running. But when you face hundreds of servers, multiple environments, complex dependencies, and strict change audit requirements, the gap between “it runs” and “it’s production-ready” is an entire engineering discipline. This article distills the core practices of production-grade Playbooks into an actionable guide, covering the full chain from structure organization to performance optimization....

April 5, 2024 · 15 mins · 3107 words · ABao