Terraform in WSL: Working Directories, Providers, and Safe Plans
Run Terraform from WSL with Linux-side providers and state, inspect init and lockfiles, review plans carefully, and avoid cross-platform cache confusion.
tag
5 posts
Run Terraform from WSL with Linux-side providers and state, inspect init and lockfiles, review plans carefully, and avoid cross-platform cache confusion.
Model Terraform instances with stable map keys, understand plan-time identity requirements, and migrate from count without accidental resource replacement.
Preserve Terraform-managed objects through address refactors with moved blocks, reviewed plans, instance mappings, and durable module upgrade history.
Use Terraform removed blocks to destroy intentionally or detach infrastructure without destroying it, with reviewed plans, ownership transfer, and recovery controls.
Use Terraform -target only for exceptional recovery, distinguish it from -replace, and return to a complete plan before normal operations resume.