Add SQLite persistence via Docker named volume

Tasks are now stored in SQLite (DB_PATH env var, defaults to ./tasks.db).
Pre-seeding runs only when the table is empty, so upgrades preserve data.
This is the v1.0.0 baseline for the persistence demo.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
davidtio
2026-02-28 14:15:17 +08:00
parent 78a5f98f11
commit 371f2c949d
3 changed files with 123 additions and 91 deletions

View File

@@ -13,7 +13,8 @@ lazy val root = project
libraryDependencies ++= Seq(
"com.greenfossil" %% "thorium" % thoriumVersion,
"com.typesafe" % "config" % "1.4.3",
"ch.qos.logback" % "logback-classic" % "1.5.6"
"ch.qos.logback" % "logback-classic" % "1.5.6",
"org.xerial" % "sqlite-jdbc" % "3.47.1.0"
),
assembly / mainClass := Some("Main"),