Commit Graph

3 Commits

Author SHA1 Message Date
Kunthawat Greethong
13f775c57c Add DATABASE_URL env var support for EmDash
- Add .env.example documenting SQLite/PostgreSQL/MySQL config
- Add src/lib/db.ts with getDatabaseConfig() helper that parses
  DATABASE_URL and returns the appropriate db config
- Update astro.config.mjs to use getDatabaseConfig() instead of
  hardcoded sqlite path

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-02 16:31:43 +07:00
Kunthawat Greethong
49725b2fd0 refactor: move data.db and uploads to storage/ folder
- Changed database path to ./storage/data.db
- Changed uploads path to ./storage/uploads
- Updated Dockerfile to create storage/uploads dir (not uploads)
- Updated entrypoint.sh to check /app/storage/data.db
- Removed COPY of uploads from builder to runner

Now all persistent data is in /app/storage/:
- /app/storage/data.db (SQLite database)
- /app/storage/uploads/ (uploaded media)

Easypanel mount: emdash-storage → /app/storage

To update EmDash: change version in package.json → push → redeploy

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-05-02 10:24:03 +07:00
Kunthawat Greethong
520c5f19e2 Initial commit: EmDash blog template
Fixed index.astro: escaped curly braces in code display block
to prevent Astro parser misinterpreting them as expressions.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-29 12:41:59 +07:00