How basecamp/once works
ONCE manages Docker-hosted web applications through an interactive TUI and CLI: users install an image, configure its hostname and settings, then monitor and operate it. The graph includes deployment, app lifecycle, backups/restores, scheduled updates, service management, and monitoring capabilities documented or visible in the supplied sources. Edges are limited to relationships evidenced by excerpts, the source index, or README; unsampled command and UI internals are represented only where documented.
Main entry points: app.go TUI application · application.go Application runtime · runner.go Background runner · dashboard.go Dashboard
Components 24
User interfaces
- CLI commands
internal/command - TUI application
internal/ui/app.go - Install flow
internal/ui/install.go - Dashboard
internal/ui/dashboard.go - App panels
internal/ui/dashboard_panel.go - App settings
internal/ui/settings.go
Application management
- Docker namespace
internal/docker/namespace.go - Application runtime
internal/docker/application.go - Image deployment
internal/command/deploy.go - Container control
internal/docker/container.go - HTTP proxy
internal/docker/proxy.go - Settings model
internal/docker/application_settings.go
Operations
- Backup and restore
internal/docker/application_backup.go - Background runner
internal/background/runner.go - Background service
internal/service/service.go - Self updater
internal/version/updater.go
Monitoring
- Metrics scraper
internal/metrics/scraper.go - Docker scraper
internal/docker/scraper.go - System scraper
internal/system/scraper.go - Usage statistics
internal/userstats/scraper.go - Statistics reader
internal/userstats/reader.go
Other components
- Operator
- Docker engine
- Host system
Connections 31
- Operator → CLI commands: runs commands
internal/command/root.go - Operator → TUI application: operates
- CLI commands → Docker namespace: restores namespace
internal/command/root.go - CLI commands → TUI application: launches
internal/command/root.go - TUI application → Install flow: selects screen
internal/ui/app.go - TUI application → Dashboard: selects screen
internal/ui/app.go - Install flow → Docker namespace: installs app
internal/ui/install.go - Dashboard → App panels: builds panels
internal/ui/dashboard.go - Dashboard → Application runtime: starts or stops
internal/ui/dashboard.go - Dashboard → App settings: opens settings
- App settings → Settings model: changes settings
- Docker namespace → Application runtime: provides apps
- Application runtime → Container control: controls
- Image deployment → Application runtime: deploys image
internal/command/deploy.go - Application runtime → HTTP proxy: configures routing
- Application runtime → Backup and restore: backs up data
internal/docker/application_backup.go - Background runner → Docker namespace: restores namespace
internal/background/runner.go - Background runner → Application runtime: checks updates
internal/background/runner.go - Background runner → Backup and restore: schedules backups
internal/background/runner.go - Background runner → Self updater: updates binary
internal/background/runner.go - Background service → Background runner: runs periodically
- TUI application → Metrics scraper: scrapes metrics
internal/ui/app.go - TUI application → Docker scraper: scrapes containers
internal/ui/app.go - TUI application → System scraper: scrapes host
internal/ui/app.go - TUI application → Statistics reader: scrapes usage
internal/ui/app.go - Statistics reader → Usage statistics: reads summaries
- Usage statistics → Docker engine: reads proxy logs
internal/userstats/scraper.go - Docker scraper → Docker engine: collects stats
- Application runtime → Docker engine: manages containers
- System scraper → Host system: collects resources
- HTTP proxy → Operator: serves web apps