# Technology Stack **Analysis Date:** 2026-03-23 ## Languages **Primary:** - Go 1.26 - Backend HTTP server and all API logic (`cmd/diunwebhook/main.go`, `pkg/diunwebhook/diunwebhook.go`) - TypeScript ~5.7 - Frontend React SPA (`frontend/src/`) **Secondary:** - SQL (SQLite dialect) - Inline schema DDL and queries in `pkg/diunwebhook/diunwebhook.go` ## Runtime **Environment:** - Go 1.26 (compiled binary, no runtime needed in production) - Bun (frontend build toolchain, uses `oven/bun:1-alpine` Docker image) - Alpine Linux 3.18 (production container base) **Package Manager:** - Go modules - `go.mod` at project root (module name: `awesomeProject`) - Bun - `frontend/bun.lock` present for frontend dependencies - Bun - `docs/bun.lock` present for documentation site dependencies ## Frameworks **Core:** - `net/http` (Go stdlib) - HTTP server, routing, and handler registration. No third-party router. - React 19 (`^19.0.0`) - Frontend SPA (`frontend/`) - Vite 6 (`^6.0.5`) - Frontend dev server and build tool (`frontend/vite.config.ts`) **UI:** - Tailwind CSS 3.4 (`^3.4.17`) - Utility-first CSS (`frontend/tailwind.config.ts`) - shadcn/ui - Component library (uses Radix UI primitives, `class-variance-authority`, `clsx`, `tailwind-merge`) - Radix UI (`@radix-ui/react-tooltip` `^1.1.6`) - Accessible tooltip primitives - dnd-kit (`@dnd-kit/core` `^6.3.1`, `@dnd-kit/utilities` `^3.2.2`) - Drag and drop - Lucide React (`^0.469.0`) - Icon library - simple-icons (`^16.9.0`) - Brand/service icons **Documentation:** - VitePress (`^1.6.3`) - Static documentation site (`docs/`) **Testing:** - Go stdlib `testing` package with `httptest` for handler tests - No frontend test framework detected **Build/Dev:** - Vite 6 (`^6.0.5`) - Frontend bundler (`frontend/vite.config.ts`) - TypeScript ~5.7 (`^5.7.2`) - Type checking (`tsc -b` runs before `vite build`) - PostCSS 8.4 (`^8.4.49`) with Autoprefixer 10.4 (`^10.4.20`) - CSS processing (`frontend/postcss.config.js`) - `@vitejs/plugin-react` (`^4.3.4`) - React Fast Refresh for Vite ## Key Dependencies **Critical (Go):** - `modernc.org/sqlite` v1.46.1 - Pure-Go SQLite driver (no CGO required). Registered as `database/sql` driver named `"sqlite"`. - `modernc.org/libc` v1.67.6 - C runtime emulation for pure-Go SQLite - `modernc.org/memory` v1.11.0 - Memory allocator for pure-Go SQLite **Transitive (Go):** - `github.com/dustin/go-humanize` v1.0.1 - Human-readable formatting (indirect dep of modernc.org/sqlite) - `github.com/google/uuid` v1.6.0 - UUID generation (indirect) - `github.com/mattn/go-isatty` v0.0.20 - Terminal detection (indirect) - `golang.org/x/sys` v0.37.0 - System calls (indirect) - `golang.org/x/exp` v0.0.0-20251023 - Experimental packages (indirect) **Critical (Frontend):** - `react` / `react-dom` `^19.0.0` - UI framework - `@dnd-kit/core` `^6.3.1` - Drag-and-drop for tag assignment - `tailwindcss` `^3.4.17` - Styling **Infrastructure:** - `class-variance-authority` `^0.7.1` - shadcn/ui component variant management - `clsx` `^2.1.1` - Conditional CSS class composition - `tailwind-merge` `^2.6.0` - Tailwind class deduplication ## Configuration **Environment Variables:** - `PORT` - HTTP listen port (default: `8080`) - `DB_PATH` - SQLite database file path (default: `./diun.db`) - `WEBHOOK_SECRET` - Token for webhook authentication (optional; when unset, webhook is open) **Build Configuration:** - `go.mod` - Go module definition (module `awesomeProject`) - `frontend/vite.config.ts` - Vite config with `@` path alias to `./src`, dev proxy for `/api` and `/webhook` to `:8080` - `frontend/tailwind.config.ts` - Tailwind with shadcn/ui theme tokens (dark mode via `class` strategy) - `frontend/postcss.config.js` - PostCSS with Tailwind and Autoprefixer plugins - `frontend/tsconfig.json` - Project references to `tsconfig.node.json` and `tsconfig.app.json` **Frontend Path Alias:** - `@` resolves to `frontend/src/` (configured in `frontend/vite.config.ts`) ## Database **Engine:** SQLite (file-based) **Driver:** `modernc.org/sqlite` v1.46.1 (pure Go, CGO_ENABLED=0 compatible) **Connection:** Single connection (`db.SetMaxOpenConns(1)`) with `sync.Mutex` guarding writes **File:** Configurable via `DB_PATH` env var, default `./diun.db` ## Platform Requirements **Development:** - Go 1.26+ - Bun (for frontend and docs development) - No CGO required (pure-Go SQLite driver) **Production:** - Single static binary + `frontend/dist/` static assets - Alpine Linux 3.18 Docker container - Persistent volume at `/data/` for SQLite database - Port 8080 (configurable via `PORT`) **CI:** - Gitea Actions with custom Docker image `gitea.jeanlucmakiola.de/makiolaj/docker-node-and-go` (contains both Go and Node/Bun toolchains) - `GOTOOLCHAIN=local` env var set in CI --- *Stack analysis: 2026-03-23*