Living Document Notice Published 2026-09-21. The evolving architecture and connected notes for this dispatch live in the Stax Digital Garden.
Embers Architecture - Node and SQLite Media Engine
Overview
Self-hosted media platforms often fail under operational maintenance overhead. Systems requiring clustered databases, message queues, and external caching layers routinely degrade when host nodes reboot or network namespaces drift.
┌─────────────────────────────────────────────────────────────┐
│ EMBERS RUNTIME ENGINE │
│ │
│ [Client Interface] ──HTTP/REST──> [API Server (Node/TS)] │
│ │ │
│ ┌───────┴──────┐ │
│ ▼ ▼ │
│ [SQLite / WAL] [Storage VFS] │
│ (hold.db) │ │
│ ┌──────┴──────┐ │
│ ▼ ▼ │
│ POSIX Disk S3 API │
└─────────────────────────────────────────────────────────────┘Runtime Components
- API Core (Node.js & TypeScript): A single Node service manages route handling, session validation, upload ingestion, and asset conversion, exposing a typed REST API directly to the browser.
- Frontend Lens (React): A responsive interface optimized for browsing and media ingestion, supporting desktop masonry and mobile interfaces without native application dependencies.
- Relational Persistence (SQLite): System state lives in an embedded SQLite database running in Write-Ahead Logging (WAL) mode. SQLite eliminates external database processes, enables simple single-file backups, and provides sub-millisecond query performance over the local filesystem.
- Storage Abstraction: Media persistence is decoupled from application logic via an abstract storage interface. Assets can target local POSIX disk directories or private S3-compatible endpoints without code modifications.
export interface StorageAdapter {
put(key: string, stream: NodeJS.ReadableStream, mimeType: string): Promise<void>;
get(key: string): Promise<NodeJS.ReadableStream>;
delete(key: string): Promise<void>;
getUrl(key: string): string | null;
}| Layer | Traditional Self-Hosted Media Suites | Embers Minimal Engine |
|---|---|---|
| Relational Core | Clustered PostgreSQL or MySQL container | Embedded SQLite (single local file) |
| Job Queue | Redis or RabbitMQ broker | In-process asynchronous task pipeline |
| Asset Storage | Tightly coupled POSIX volume paths | Pluggable driver (POSIX mount or S3 API) |
| Deployment Footprint | Multi-container Docker Compose mesh | Single container (Node + SQLite + assets) |
Architectural Invariants
- Deterministic Execution: Operations execute within deterministic memory bounds without external side effects.
- Sovereignty: Storage and state replication guarantee zero unauthenticated telemetry or vendor lock-in.
| Invariant Property | Operational Guarantee |
|---|---|
| System Invariant | Embers rejects all public bearer links and automated facial indexing; access is strictly confined to authenticated household sessions and explicit PIN gates. |
# Verify guest access PIN requirement and zero public bearer URLs
curl -s -o /dev/null -w "%{http_code}" http://127.0.0.1:3000/media/stream/circle_01- Directus Target: embers
- Garden Source Reference: MOC - The Digital Necropolis and Cold Decadal Storage, MOC - Bosun PKM Tools
- Garden Source Reference: EMB-1012 - Embers Architecture - Node and SQLite Media Engine, BSN-1001 - The Bosun Architecture Manifesto