Adventure 02: Building CloudHaven | 🟡 Intermediate: The Modular Metropolis

Welcome to the intermediate level of the Building CloudHaven challenge adventure! Your mission: modernize CloudHaven’s infrastructure from manual provisioning to a self-service platform. This is a hands-on journey through OpenTofu.

The entire infrastructure is pre-provisioned in your Codespace — OpenTofu and mock cloud services are ready to go when you need them. You don’t need to set up anything locally. Just focus on solving the problem.

:bullseye: The Challenge

After fixing the Foundation Stones, CloudHaven is thriving! The city has grown to three districts, and the Guild decided to refactor the infrastructure into reusable modules. A senior engineer started the work using Test-Driven Development - writing tests first, then implementing. But they were called away before finishing, leaving behind working tests… and buggy code that doesn’t match them. Your mission: fix the bugs, complete the integration test, and deploy the infrastructure.

:brain: What You’ll Learn

  • OpenTofu module structure & testing with tofu test

  • Test-Driven Development (TDD) workflow

  • Input validation

  • How to use the moved block for refactoring infrastructure

:bullseye: Objective

By the end of this level, you should have:

  • All tests of the districts module pass

  • A completed integration test that applies infrastructure against the mock GCP API to verify end-to-end functionality

  • Three districts deployed with correctly configured infrastructure (vaults and ledgers)

:information_source: Important: The tests are correct - they define the expected behavior. Your job is to fix the implementation to match what the tests expect. Don’t modify existing tests unless a comment tells you to; let the tests guide your fixes.

:alarm_clock: Deadline

Sunday, 1 February 2026 at 23:59 CET

:information_source: You can still complete the challenge after this date, but points will only be awarded for submissions before the deadline.

:chart_increasing: Level: :yellow_circle: Intermediate

:rocket: Get Started

:backhand_index_pointing_right: Start the Challenge

:speech_balloon: Discussion

Share your solutions and questions in this thread. :rocket: Good luck, and we can’t wait to see your solutions!

3 Likes

Apologies. I have used up my free quota of codespaces this month. Is it okay to defer the deadline a week later (i.e. 7 Feb or later)?

Hey :slight_smile:

Unfortunately, this would create too much overlap with the February adventure that is coming next month. Sorry!

But in theory, you should be able to run the challenge locally as GitHub Codespaces are just devcontainers in the end. Also, the deadline just means that no points will be rewarded afterwards. You can always play all past challenges for learning.

I created a GitHub issue to take a look at local execution as well: Test & document local execution · Issue #14 · dynatrace-oss/open-ecosystem-challenges · GitHub

2 Likes


Hello i managed to find the solution but when i try to run the ci pipeline i get an error:

1 Like

Oh no. Thanks for reporting and sorry for the inconveniences!

I’ll take a look and get back to you once it’s fixed.

Good morning,

I took a look at your adventure and there are still a few tiny things missing. I had a hard time with the smoke test on this one as I couldn’t test if e.g. all necessary conditions are covered in the integration test.

By looking at your code, I realized that the GitHub action verification script is definitely not giving away enough information to make up for the smoke test. Therefore, I added some more hints there in case something fails. If you rerun it and then open the logs for your run, you should see much more details.

Thanks again for reporting and have fun playing :slight_smile:

1 Like

Good Morning

Thank u for the fast reaponse and for updating the ci pipeline indeed the hints were very helpfull. Just confirming that on my side is all good now.

Regrads

2 Likes

1 Like

The expert level is now live. And the deadline for all 3 levels has been extended until Wednesday, 4 February 2026 at 23:59 CET

:backhand_index_pointing_right: Adventure 02: Building CloudHaven | :red_circle: Expert: The Guardian Protocols

:sweat_smile: almost fell behind

1 Like