العودة إلى الدورة

الموديولات (Modules): إنشاء مكونات قابلة لإعادة الاستخدام

احتراف البنية التحتية كبرمجيات (Terraform & OpenTofu)

The Lego Blocks of DevOps

Don't write 500 lines of code in one file. Group your code into Modules. A module is just a folder containing .tf files.

Calling a Module

hcl module "web_cluster" { source = "./modules/autoscaling" cluster_name = "marketing-site" min_size = 2 }

This makes your code organized, easy to read, and allows you to share common setups across different projects.