A self-hosted, minimal blog platform with an advanced markdown editor, role-based access control, and dynamic OG image generation. Built with Astro SSR + SQLite.
- Pure Astro SSR with Node standalone adapter
- Bun runtime and package manager
- Drizzle ORM + SQLite via libsql
- Lucia Auth v3 with cookie-based sessions and Bcrypt
- Tailwind CSS v4 with CSS-first configuration
- Split-pane Markdown Editor with live preview
- Role-Based Access Control (Owner, Admin, User)
- Open Graph image generation per post
- Dark/Light Mode with system preference support
- View Transitions for smooth navigation
- Responsive Design for all devices
- Sitemap auto-generation
- Docker ready for self-hosting
The clean, minimal homepage lists all published posts with reading time estimates and author attribution.
| Light Mode | Dark Mode |
|---|---|
![]() |
![]() |
Posts are rendered with full markdown support including headings, bold text, lists, code blocks, blockquotes, and tag badges.
The dashboard provides a complete overview of all posts with status badges, filtering, sorting, and quick actions for editing and deleting.
The split-pane editor features live markdown preview, import/export support, post settings (slug, excerpt, tags, publish date, status), and a resizable layout.
Simple, clean authentication with username and password. Supports registration for new users.
- Bun installed
- Docker (optional, for containerized deployment)
Create a .env file:
DB_FILENAME=miniblog.db
OWNER_CREDENTIALS=admin:$2y$10$...
HOST=0.0.0.0
PORT=4321
NODE_ENV=productionGenerate the OWNER_CREDENTIALS hash with htpasswd:
htpasswd -nbB -C 10 username passwordbun installbun run db:pushbun run devbun run build
bun dist/server/entry.mjsTests run using a separate dev database.
bun run test # Unit tests (Vitest)
bun run test:e2e # E2E tests (Playwright)
bun run test:all # Run bothdocker compose up --buildOr pull from the registry:
docker pull ghcr.io/hekpyto/miniblog| Layer | Technology |
|---|---|
| Framework | Astro v5 (SSR) |
| Styling | Tailwind CSS v4 + @tailwindcss/typography |
| Database | SQLite via @libsql/client |
| ORM | Drizzle ORM |
| Auth | Lucia v3 + oslo (Bcrypt) |
| Markdown | markdown-it + Shiki (dual-theme syntax highlighting) |
| OG Images | Satori + Sharp |
| Runtime | Bun |
| Testing | Vitest + Playwright |
| CI/CD | GitHub Actions |
| Role | Access |
|---|---|
| Owner | Full access including user management |
| Admin | Dashboard and editor |
| User | Public pages only |





