Open-source IT asset management for teams of any size.
Track hardware, software licences, consumables, and accessories — with role-based access, audit logging, SSO, and integrations built in.
Features · Quick Start · Deployment · Configuration · Contributing
|
|
|
|
|
|
|
|
| Layer | Technology |
|---|---|
| Framework | Next.js 16 (App Router, Turbopack) |
| Language | TypeScript 5.9 |
| Database | PostgreSQL + Prisma 7 (42 models) |
| Auth | BetterAuth — sessions, SSO, MFA |
| UI | Tailwind CSS 4 + shadcn/ui |
| Validation | Zod |
| Charts | Recharts |
| Monitoring | Sentry / Glitchtip |
| Testing | Vitest + Playwright |
- Node.js 18+ or Bun
- PostgreSQL database
git clone https://github.com/luca-fitseveneleven/assetTracker.git
cd assetTracker
bun installcp .env.example .envSet at minimum:
DATABASE_URL=postgresql://user:password@localhost:5432/assettracker
BETTER_AUTH_URL=http://localhost:3000
BETTER_AUTH_SECRET= # generate with: openssl rand -base64 32
ENCRYPTION_KEY= # generate with: openssl rand -hex 32npx prisma migrate deploy
npx prisma generatebun run create-adminbun devOpen http://localhost:3000 and sign in.
docker build -t asset-tracker .
docker run -p 3000:3000 --env-file .env asset-trackerservices:
app:
build: .
ports:
- "3000:3000"
env_file: .env
depends_on:
- db
db:
image: postgres:16-alpine
environment:
POSTGRES_DB: assettracker
POSTGRES_USER: assettracker
POSTGRES_PASSWORD: changeme
volumes:
- pgdata:/var/lib/postgresql/data
volumes:
pgdata:Set the environment variables in the Vercel dashboard and connect your PostgreSQL database.
bun run build
bun startAll configuration is via environment variables. Copy .env.example for the full reference.
| Category | Key Variables | Required |
|---|---|---|
| Database | DATABASE_URL |
Yes |
| Auth | BETTER_AUTH_URL, BETTER_AUTH_SECRET |
Yes |
| Encryption | ENCRYPTION_KEY |
Recommended |
| Microsoft SSO | MICROSOFT_CLIENT_ID, MICROSOFT_CLIENT_SECRET, MICROSOFT_TENANT_ID |
No |
EMAIL_PROVIDER, provider API keys |
No | |
| Storage | STORAGE_PROVIDER (local, s3, azure) |
No |
| Integrations | Slack/Teams webhooks, Freshdesk API key | No |
| Billing | STRIPE_SECRET_KEY, STRIPE_WEBHOOK_SECRET |
No |
| Redis | UPSTASH_REDIS_REST_URL, UPSTASH_REDIS_REST_TOKEN |
No |
| CAPTCHA | TURNSTILE_SECRET_KEY, NEXT_PUBLIC_TURNSTILE_SITE_KEY |
No |
| Self-hosted | SELF_HOSTED=true — disables landing page, pricing, registration |
No |
| Command | Description |
|---|---|
bun dev |
Start dev server (Turbopack) |
bun run build |
Production build |
bun start |
Start production server |
bun run lint |
ESLint |
bun run format |
Prettier |
bun run test |
Unit tests (Vitest) |
bun run test:e2e |
E2E tests (Playwright) |
bun run db:seed |
Seed database |
bun run create-admin |
Create admin user |
src/
├── app/ # Next.js App Router — pages & API routes
│ ├── api/ # 100+ REST API endpoints
│ ├── assets/ # Asset management pages
│ ├── dashboard/ # Customizable widget dashboard
│ ├── admin/ # Admin settings & configuration
│ └── ... # Licences, accessories, consumables, etc.
├── components/ # Shared UI components (shadcn/ui)
├── hooks/ # Custom React hooks
├── lib/ # Core utilities
│ ├── integrations/ # Slack / Teams notification module
│ ├── storage/ # Pluggable file storage (local, S3, Azure)
│ ├── rbac.ts # Permission system (35 permissions)
│ ├── workflow-engine.ts # Automated workflow execution
│ └── ... # Auth, validation, encryption, webhooks
└── ui/ # Page-specific UI components
prisma/
└── schema.prisma # Data model (42 models)
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch (
git checkout -b feature/my-feature) - Run linting and tests (
bun run lint && bun run test) - Commit with a conventional commit message
- Open a Pull Request
This project uses Husky pre-commit hooks with Prettier and ESLint.
MIT License — see LICENSE for details.
Copyright (c) 2026 Luca Gerlich