Schema Location
The database schema is defined insrc/lib/db/schema.ts using Drizzle ORM’s declarative syntax.
Tables
registry
Stores container registry configurations and authentication state.Columns
Primary key, auto-generated UUID v7
- Generated using
uuid()from theuuidpackage - Version 7 UUIDs are time-sortable
Display name for the registry
- User-friendly identifier
- Not unique (multiple entries could have the same name)
- Cannot be null
Registry URL
- Must be unique across all registry entries
- Examples:
docker.io,ghcr.io,quay.io - Cannot be null
Authentication status
- Stored as SQLite integer (0 = false, 1 = true)
- Defaults to
false - Indicates whether the user is currently authenticated
Constraints
- Primary Key:
id - Unique:
url - Not Null:
name,url
Usage Example
seeds
Tracks database migration and seed script execution.Columns
Primary key, auto-generated UUID v7
- Generated using
uuid()from theuuidpackage - Unique identifier for each seed entry
Seed script name
- Must be unique
- Identifies the migration or seed file
- Cannot be null
Whether the seed has been applied
- Stored as SQLite integer (0 = false, 1 = true)
- Defaults to
false - Prevents duplicate migrations
Constraints
- Primary Key:
id - Unique:
name - Not Null:
name
Usage Example
Database Configuration
The database is configured using Drizzle ORM with LibSQL client.Connection
Migrations
Migrations are managed through Drizzle Kit:Type Safety
Drizzle ORM provides full TypeScript type safety:Registry Type
InsertRegistry Type
Query Builder
Drizzle provides a type-safe query builder:Database Location
The SQLite database file is stored locally:- Development: Project directory
- Production: Application data directory (platform-specific)