👑 Premium Sign in Sign up

IA01 · Infrastructure as Code & policy

Terraform Modules, Remote State & Plan Review

Use a module for the network, keep state remote with locking and review the plan in a pull request.

📶 L300⏱ 75 min🧪 Live lab

🎯 You will learn to

  • Use modules
  • Use remote state and locks
  • Review plans

🧪 Live environment

Runs entirely in your browser: nothing is installed, no real cloud account is used and your code is never sent to our server.

Loading the lab…

✅ Steps & checkpoints

🗺️ Modules and remote state

A root module calls a network module; state lives in a locked remote backend and the plan is reviewed in a pull request.

Modules and remote stateA root module calls a network module; state lives in a locked remote backend and the plan is reviewed in a pull request.Root modulemodules/networkRemote state+ lockplanPR reviewplan commentapplyafter mergesourcereadwrite + unlockData storeTool / stepComputePerson / client

The 2D diagram shows the exact flow, ports and trust boundaries. The 3D scene is a concept view of the same parts; packets travel along the same arrows.

🤔 Think about it

What happens if two people apply at once without a lock?

🛡️ Safety & cost

Every apply here is simulated. Always review a real plan before you apply it.

🧹 Cleanup

Run destroy in the simulator, and in real life check that state is empty.

📚 Reference documents

Official sources, checked on 5 Nov 2026. Cloud services change often; check the official page before relying on a feature. All references