Files
pulse/internal/updates
rcourtman 2408d8004c feat: add update system foundation with adapter pattern
Add infrastructure for deployment-agnostic update management:

**Update History (Audit Log):**
- JSONL-based audit log (/var/lib/pulse/update-history.jsonl)
- Tracks all update attempts with full metadata
- In-memory cache for fast queries
- Schema designed for future DB migration

**Updater Interface:**
- Defines contract for deployment-specific update logic
- SupportsApply(), PrepareUpdate(), Execute(), Rollback()
- Registry pattern for managing multiple adapters
- Progress callbacks for real-time UI updates

**Adapters Implemented:**
- InstallShAdapter: Wraps install.sh (systemd/LXC)
  * Full automation support
  * Captures stdout/stderr to log files
  * Parses backup paths from output
  * Maintains install.sh as single source of truth
- DockerUpdater: Instruction-only (manual)
- AURUpdater: Instruction-only (package manager)

Key design decisions:
- install.sh remains unchanged (backward compatible)
- All update mechanisms funnel through adapters
- Audit log records all updates (manual + automated)
- Thin wrapper approach - no logic duplication

Next: Wire up API endpoints and frontend integration.
2025-10-10 15:39:47 +00:00
..
2025-10-09 23:24:03 +00:00