Architecture

Harbour's Artisan commands adapt input and output around an injectable WorkspaceManager. The manager is a small lifecycle facade; SetupSequence and TeardownSequence own orchestration, with dedicated variable, database, and managed-infrastructure collaborators. Orchestration remains outside the console layer. Harbour configuration is validated once into a typed value object, and each lifecycle collaborator is registered in Laravel's container rather than constructed inline by the manager.

Harbour component boundaries

Lifecycle

Harbour workspace lifecycle

Setup records preparing before external mutation and persists every acquired allocation or resource. Failures retain the recorded subset. A later setup may finish only an explicitly pending SQL or Docker create; confirmed resources whose ownership evidence vanished require teardown. Teardown walks resources in reverse order and converges safely on absent.

Domain boundaries

Architectural decisions

The repository contains the complete rationale and invariants:

Read the full architecture document for state schemas, lock ordering, identifier rules, and teardown invariants.