How tunnel-labs/localdev works
localdev is a host-based local development process manager with an interactive terminal UI. The principal workflow is: a developer launches the CLI, localdev loads project configuration and prepares its proxy/domain setup, configured services run as processes, and their statuses and logs appear in the TUI. Users can also inspect logs and statuses, control services, and route local domains to development services. The README documents proxy and domain configuration; unsampled implementation details are represented only where those documented capabilities identify a subsystem.
Main entry points: service.ts Service lifecycle · start.ts Startup orchestration · commands.ts Interactive commands · terminal.ts Terminal renderer
Components 21
Startup and configuration
- CLI entry
bin/localdev.ts - Package API
exports/main.ts - Config loader
utils/config.ts - Config model
types/config.ts - Startup orchestration
utils/start.ts
Local networking
- Proxy and domains
utils/setup.ts - Local certificates
utils/mkcert.ts - DNS setup
utils/powershell.ts
Service runtime
- Service lifecycle
utils/service.ts - Process runner
utils/process.ts - Log files
utils/process.ts
Terminal interface
- Interactive commands
utils/commands.ts - Terminal renderer
utils/terminal.ts - Log formatting
utils/logs.ts - Shared UI state
utils/state.ts - Service statuses
command-panes/service-statuses.tsx - Logs view
command-panes/logs.tsx - Help view
command-panes/help.tsx - Service hijack view
command-panes/hijack.tsx
Other components
- Developer
- Local service targets
Connections 27
- Developer → CLI entry: launches
readme.md - Developer → Package API: imports
readme.md - CLI entry → Startup orchestration: starts
bin/localdev.ts - Package API → Startup orchestration: exports
exports/main.ts - Startup orchestration → Config loader: loads config
utils/start.ts - Config loader → Config model: validates
types/config.ts - Startup orchestration → Proxy and domains: sets up
utils/start.ts - Proxy and domains → Local certificates: creates certs
utils/setup.ts - Proxy and domains → DNS setup: configures DNS
utils/setup.ts - Startup orchestration → Service lifecycle: creates services
utils/start.ts - Service lifecycle → Process runner: spawns
utils/service.ts - Process runner → Log files: writes and reads
utils/process.ts - Service lifecycle → Shared UI state: updates status
utils/service.ts - Service lifecycle → Log files: streams logs
utils/service.ts - Startup orchestration → Terminal renderer: starts UI
utils/start.ts - Terminal renderer → Shared UI state: renders state
utils/terminal.ts - Terminal renderer → Log formatting: formats logs
utils/terminal.ts - Terminal renderer → Service statuses: opens initially
utils/terminal.ts - Interactive commands → Service lifecycle: controls services
utils/commands.ts - Interactive commands → Service statuses: selects view
utils/commands.ts - Interactive commands → Logs view: selects view
utils/commands.ts - Interactive commands → Help view: selects view
utils/commands.ts - Interactive commands → Service hijack view: selects view
utils/commands.ts - Service statuses → Service lifecycle: reads statuses
command-panes/service-statuses.tsx - Logs view → Shared UI state: uses state
command-panes/logs.tsx - Service hijack view → Service lifecycle: uses service
command-panes/hijack.tsx - Local service targets → Proxy and domains: receives proxied traffic
readme.md