StaffCoder
Terraform
TerraformTerraform 1.15Linux CLI
21 modules · 84 challengesSign up
Modules21 modules · 84 challenges
Work with count, for_each and dynamic blocks to collapse copies into one resource, key instances by name, and generate nested blocks from data. Finish by building a fleet driven entirely by a data file.
Finish every challenge, or complete the star challenge, to complete the module.

Challenges

4 challenges

Counted Copies

Sign up to unlock
—No data yeteasy
About this challenge

Collapse pasted copies into one counted resource with index-derived names and gate an optional resource on a boolean through count.

Solved in a browser IDE and graded by tests. Sign up to solve

Keyed Instances With For-Each

Sign up to unlock
—No data yeteasy
About this challenge

Convert a counted collection to for-each keyed by name, derive per-instance attributes from key and value, and prove middle removals touch only one instance.

Solved in a browser IDE and graded by tests. Sign up to solve

Dynamic Nested Blocks

Sign up to unlock
—No data yeteasy
About this challenge

Generate a launch template's disk blocks dynamically from a collection variable, in collection order and including the empty case.

Solved in a browser IDE and graded by tests. Sign up to solve

Fleet From Data

STAR
Solving it completes the module
—No data yeteasy
About this challenge

Drive a fleet of keyed, counted, gated and dynamically nested resources from one structured variable and prove every data edit touches only what changed.

Solved in a browser IDE and graded by tests. Sign up to solve

We use cookies that are necessary to run Staffcoder, and optional analytics cookies to see which pages get used. Analytics stays off unless you accept. Read our Cookie Policy.