Production-ready Rust web backend template.
- Auth:Session (Redis), email/password (Argon2), OAuth2 (Google, GitHub), TOTP 2FA
- Users & Posts:Profiles, image uploads (R2), CRUD with ownership
- Search:Full-text via MeiliSearch, auto-indexed by worker
- Background Jobs:NATS JetStream worker (email, indexing, cleanup, cron)
- Email:SMTP templates (Lettre + MRML + MiniJinja)
- Rate Limiting:Sliding window (Redis Lua), per-route
- API Docs:Auto-generated Swagger UI (debug builds)
- Deploy:Docker multi-stage, GitHub Actions CI/CD
git clone https://github.com/levish0/AxumKit.git && cd AxumKit
cp .env.example .env # edit with your config
cd crates/migration && cargo run && cd ../.. # migrations
cargo run -p server # API server
cargo run -p worker # worker (separate terminal)crates/
├── server # API (handlers → services → repositories → entities)
├── worker # Background jobs (NATS consumers, cron)
├── config # Env config
├── constants # Shared constants
├── dto # Request / response types
├── entity # SeaORM models
├── errors # Centralized error handling
└── migration # DB migrations
Env vars from .env, validated at startup. See .env.example for the full list.
