Miconsul is a patient appointment planner and notification center.
- Go + Fiber v3
- SQLite + GORM
- Templ + HTMX + DaisyUI/TailwindCSS
- OpenTelemetry (traces, metrics, logs)
Prerequisites:
- Go 1.26+ (with CGO support for SQLite)
make- Bun
- Docker (optional, for local observability stack)
Preferred local toolchain path is mise.
Alternatives remain valid:
asdfhomebrew
Use your manager to install runtime/toolchain binaries (go, bun).
Then use project tasks for repository setup:
make install/deps: installs project dependencies (go mod download,bun install)make install/tools: installs optional local CLIs (templ,go-localize)
Create your local environment file:
cp .env.example .envMinimum app variables to verify/update in .env:
APP_ENV,APP_PORT,APP_NAME,APP_PROTOCOL,APP_DOMAIN,APP_VERSIONCOOKIE_SECRET,JWT_SECRETDB_PATH,SESSION_DB_PATH
Optional but commonly used:
OTEL_EXPORTER_OTLP_ENDPOINT,OTEL_EXPORTER_OTLP_INSECUREJOBS_ENABLED,JOBS_UI_ENABLED,VALKEY_HOST,VALKEY_PORT,VALKEY_DBLOGTO_URL,LOGTO_APP_ID,LOGTO_APP_SECRET,LOGTO_RESOURCE
Install project tooling:
make install/depsOptional local CLI tools (templ, go-localize):
make install/toolsRun in development mode (Tailwind + Templ watch + hot reload):
make devRun once without watchers:
make runList all available tasks:
makeMost used commands:
# quality
make fmt
make vet
# generate frontend artifacts
make templ/build
make locales/build
# tests
make test
make test/race
make test/coverage
# database
make db/setup
make db/seed
make migrations/statusDefault tests:
make testOptional in-memory sqlite mode for faster ephemeral runs:
MICON_TEST_SQLITE_INMEMORY=1 go test ./...Coverage helpers:
make test/coverage
make test/coverage/service-leaderboard
make test/coverage/htmlMore details: docs/testing.md.
Recreate DB, run migrations, and seed:
make db/setupRun seeds only:
make db/seedSeed command with custom amounts:
go run -tags fts5 cmd/seed/main.go --users=2 --clinics=10 --patients=20 --appointments=40Local load generation helpers:
make obs/load/light
make obs/load/medium
make obs/load/heavyRunbook: docs/observability_runbook.md.
Jobs operations runbook: docs/jobs_runbook.md.
Project entry points:
- App:
cmd/app/main.go - Seed command:
cmd/seed/main.go - Router wiring:
internal/routes/router.go - HTTP server/middleware:
internal/server - Services/handlers:
internal/services - Views:
internal/views/*.templ
Architecture guidelines and diagrams:
docs/architecture.md
Deployment docs are being prepared:
docs/deployment.md
Current cleanup/refactor stream:
- Refresh README and remove stale sections.
- Remove legacy
internal/lib/urlusage and rely on bootstrap env wiring. - Remove untyped locals in appointments/dashboard view data flow.
- Reuse DB logger path for migrations so migration logs reach Loki/OTEL.
MVP demo: