Exercise 2: Why the Capstone Chose Separate Directories Over Workspaces — Possible Solution ==================================================================== Chapter 8's own conclusion, reached via Exercise 2's own comparison, was that a team managing a genuinely high-stakes production environment should prefer separate directories over workspaces, specifically because workspaces only isolate STATE -- the configuration, backend, and (critically) provider credentials are all still shared across every workspace. A mistaken workspace selection can still execute a real `apply` against real production infrastructure using real production credentials, since nothing about workspace selection itself changes which credentials are available in that shell session. This capstone's own environment is exactly the kind of case that reasoning applies to: it includes a production database with `prevent_destroy = true` protection (Step 5) precisely because an accidental destroy would be severe -- the same category of "genuinely high-stakes" resource Chapter 8's own Exercise 2 discussion was built around. Using workspaces here would mean the dev and prod copies of this environment share the same credentials and the same configuration, with only state kept separate -- so a team member intending to test something in a dev workspace, but accidentally still selected into prod, could still run a real, credentialed `apply` against the production database and the rest of the production environment, with nothing structurally preventing it. Separate `environments/dev/` and `environments/prod/` directories, each with their own backend key and credentials, remove that failure mode by construction: someone working in the dev directory simply doesn't have production credentials available in that context at all, so even a serious mistake can't reach the production resources this capstone is specifically trying to protect with Step 5's `lifecycle` block. WHY THIS WORKS AS AN ANSWER ------------------------------ This ties the capstone's specific choice directly back to Chapter 8's own stated reasoning (shared credentials as the real risk with workspaces) and connects it concretely to this capstone's own production database and its Step 5 protection, rather than restating Chapter 8's general conclusion without applying it to this specific scenario.