AckLab is a production-oriented Next.js MVP for interactive networking fundamentals. It includes subnet visualization, binary conversion, TCP handshake animation, OSI exploration, DNS flow simulation, and graph-based routing.
The current product is intentionally local-mock only. It does not implement a backend, database, authentication, payments, subscriptions, or external APIs.
- Next.js App Router with standalone production output
- TypeScript strict mode
- TailwindCSS v4
- shadcn-compatible UI primitives
- Framer Motion
- Lucide React
- React Hook Form and Zod
- Zustand
- pnpm
- ESLint, Prettier, Husky, lint-staged
- Docker multi-stage production build
- GitHub Actions CI
app/ App Router pages and global layout
src/components/ui/ shadcn-compatible primitives
src/components/layout/ shell, nav, command menu, theme provider
src/components/shared/ reusable product UI
src/components/visualizations/
src/features/ domain-owned interactive tools and visualizers
src/services/ future auth/API/payment/progress contracts only
src/data/ local mock data
src/types/ shared TypeScript contracts
src/config/ app and environment configuration
src/constants/ navigation and constants
docs/ architecture and deployment documentation
Future infrastructure concerns are represented by interface contracts in src/services/, but no network calls or server-side integrations are active.
Use pnpm through Corepack:
corepack enable
corepack prepare pnpm@11.0.9 --activate
pnpm install
cp .env.example .env.local
pnpm devOpen http://localhost:3000.
pnpm dev # start local Next.js dev server
pnpm build # create production build
pnpm start # run production server after build
pnpm lint # run ESLint
pnpm typecheck # run TypeScript checks
pnpm format # write Prettier formatting
pnpm format:check # verify Prettier formatting
pnpm docker:build # build local production Docker image
pnpm docker:run # run local production Docker image
pnpm docker:compose # run Compose-based local container test
pnpm clean # remove generated build artifactsEnvironment validation lives in src/config/env.ts.
Copy .env.example to .env.local for local development:
cp .env.example .env.localPublic variables:
NEXT_PUBLIC_APP_URL: browser-visible app URL.
Private placeholders for future integrations:
AUTH_SECRETDATABASE_URLSTRIPE_SECRET_KEYANALYTICS_WRITE_KEY
Do not expose secrets through NEXT_PUBLIC_. Any value with that prefix can be bundled into client-side JavaScript.
Build and run the production image:
pnpm docker:build
pnpm docker:runOr use Compose for local container testing:
pnpm docker:composeThe Dockerfile uses:
- pnpm with frozen lockfile
- multi-stage builds
- Next.js
output: "standalone" - non-root runtime user
- port
3000
No PostgreSQL, Redis, Nginx, Kubernetes, Terraform, or cloud-specific infrastructure is included.
GitHub Actions workflow: .github/workflows/ci.yml
CI runs on push and pull_request:
- checkout
- setup pnpm
- setup Node.js
- install with frozen lockfile
- lint
- typecheck
- build
- Import the repository into Vercel.
- Use pnpm as the package manager.
- Build command:
pnpm build. - Add
NEXT_PUBLIC_APP_URLfor each environment. - Keep future secrets server-only and never prefix private values with
NEXT_PUBLIC_.
Use the included Dockerfile for production-style container builds:
docker build -t acklab:local .
docker run --rm -p 3000:3000 acklab:local- Security headers are configured in
next.config.ts. - A report-only Content Security Policy placeholder is included for tightening before production enforcement.
- No secrets are required for the MVP.
.env.localand other local environment files are ignored by Git.- Runtime Docker container runs as a non-root user.
Dependency audit:
pnpm audit- Create a branch.
- Run
pnpm install. - Make scoped changes.
- Run
pnpm lint,pnpm typecheck, andpnpm build. - Commit with the Husky pre-commit hook enabled.
- Open a pull request and wait for CI.
- Course paths and guided lessons
- Quiz engine with review mode
- User progress persistence
- Packet analyzer and HTTP inspector
- Port reference and latency visualizer
- Secure auth, RBAC, subscriptions, and billing
- Rate limiting, analytics, secure sessions, and audit logs
- Admin dashboard
See docs/architecture.md and docs/deployment.md for more detail.