Skip to main content
ubx plan compiles .iac files and runs pulumi preview to show what changes will be made — without deploying.

Usage

ubx plan [path] [flags]

Examples

ubx plan
ubx plan ./stacks/networking
ubx plan --env prod
ubx plan --target unit.aws_rds_instance.db
ubx plan --target unit.aws_rds_instance.db --target unit.aws_s3_bucket_v2.assets

Flags

FlagDescription
--env stringTarget environment
--stack stringTarget stack name
--target stringArrayTarget a specific resource (repeatable)
--no-colorDisable color output

Output

  ◆ Compile    stack.iac → .ubx/index.ts
  ◆ Stack      dev
  ◆ Packages   ready

  ─── Preview ────────────────────────

  +  aws:rds:Instance         db           (new)
  +  aws:s3:BucketV2          assets       (new)
  ~  aws:s3:BucketV2          logs         (update)

  2 to create · 1 to update · 0 to destroy

Resource Symbols

SymbolMeaning
+Create
~Update
-Delete
±Replace (delete + create)

AI Summary and Cost Estimate

When AI is enabled, ubx plan appends:
  ─── AI Summary ─────────────────────

  This plan creates a PostgreSQL database and an S3 storage bucket.

  Risk: medium — new database with hardcoded credentials
  Next: verify db_password is set before applying

  ─── Cost Estimate ──────────────────

  ✓  Estimated monthly cost: ~$13.50  (high confidence)
  RDS PostgreSQL db.t3.micro    $13.50   on-demand, us-east-1
  S3 bucket (assets)            $ 0.00   minimal usage assumed
Configure in ubx.yaml:
ai:
  enabled: true
  api_key: "sk-ant-..."
  features:
    plan_summary: true
    cost_estimate: true

--target Flag

Supported address formats:
--target unit.resource_type.name
--target component.name
--target deploy.helm.name
--target sync.argocd.name
input, output, local, and other non-resource block types are not supported.