~/talk

Meet the experts: Terraform module design

Talkat HashiConf 2024 · 2024-10-14..10-16· [devops-and-delivery]
links:none on file
links:none on file
slides:none on file

Practical rules for Terraform modules: favor default null for optional inputs, validate complex object variables and provide examples, place locals near the resources that use them, use count only for true conditionals and prefer for_each with keyed maps for clean outputs, avoid heavy for_each when creating hundreds of identical resources, output whole resource objects when helpful, test examples with terraform test or Terratest in a sandbox CI pipeline, enforce semver for breaking changes and generate docs with terraform-docs plus simple diagrams.

AI-written summary · about

  1. 0:00Introductions and background
  2. 1:20Fundamentals of module design
  3. 3:11Input variables and nulls
  4. 6:13Managing local values
  5. 8:14Resource loops and iteration
  6. 13:00Designing module outputs
  7. 15:58Version control and updates
  8. 19:59Testing strategies
  9. 24:15Documentation best practices
  10. 27:14When not to write modules
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.