Skip to main content
The workspace block defines a multi-stack orchestration manifest. Used with ubx workspace plan and ubx workspace apply to deploy stacks in topological order.

Syntax

workspace "name" {
  stack "stack_name" {
    path       = "./stacks/networking"
    depends_on = ["other_stack"]
  }
}

Example

workspace "platform" {
  stack "networking" {
    path = "./stacks/networking"
  }

  stack "eks" {
    path       = "./stacks/eks"
    depends_on = ["networking"]
  }

  stack "apps" {
    path       = "./stacks/apps"
    depends_on = ["networking", "eks"]
  }
}

Commands

ubx workspace plan platform    # preview all stacks in order
ubx workspace apply platform   # deploy all stacks in order

Stack Fields

FieldRequiredDescription
pathyesRelative path to the stack directory
depends_onnoList of stack names that must deploy first

Topological Sort

ubx performs a topological sort on depends_on before deploying. Circular dependencies are detected and reported as compile errors:
✗  workspace "platform": circular dependency detected: eks → apps → eks

No TypeScript Emitted

workspace blocks are orchestration-only — no TypeScript is emitted.