No description
  • TeX 62.8%
  • TypeScript 22.1%
  • Go 13.8%
  • HTML 1%
  • PowerShell 0.1%
  • Other 0.2%
Find a file
Codex babd7c1962
Some checks failed
CI / build-and-test (push) Has been cancelled
course2
2026-05-11 15:25:47 +03:00
.github/workflows
apps
autoreferat
deploy
docs
overleaf_packages
overleaf_singlefile
packages
report
scripts
thesis
tmp_review_pages
tmp_thesis_pages
.codex
.dockerignore
.env
.env.production.example
.gitignore
docker-compose.yml
go.work
package-lock.json
package.json
README.md
tmp_autoreferat.txt

TechZone Store (Expanded)

Stack

  • Frontend: Next.js App Router + BFF (apps/web)
  • Backend: Go modular monolith (apps/api)
  • Database: Postgres
  • Object storage (local): MinIO

Delivered modules

  • Storefront: catalog, product, cart, checkout, category/brand/promo/content pages
  • Auth + RBAC: register/login/logout/refresh/me (customer/manager/admin)
  • Account: profile, addresses, orders, wishlist, compare, bonuses, coupons, subscriptions
  • Mock payments: online_mock, cash_on_delivery, intent lifecycle
  • Admin CRM: catalog/content/orders/customers/inventory/returns/finance/analytics/rbac

Quick start with Docker

  1. Make sure Docker Desktop is running.
  2. Start the app:
    • docker compose --profile demo up --build -d
  3. Open the storefront:
    • http://localhost:3000

The Docker setup starts Postgres, MinIO, runs database migrations, loads demo data, starts the Go API, and starts the Next.js web app.

Useful local URLs:

  • Store: http://localhost:3000
  • Account login: http://localhost:3000/auth/login
  • Admin dashboard: http://localhost:3000/admin/dashboard
  • API health: http://localhost:8080/healthz
  • MinIO console: http://localhost:9001

Default local credentials:

  • Admin: admin@example.com / Admin123!
  • MinIO: minioadmin / minioadmin

Useful Docker commands:

  • View logs: docker compose logs -f
  • Stop containers: docker compose down
  • Stop and remove local data: docker compose down -v
  • Restart with fresh demo data: docker compose down -v && docker compose --profile demo up --build -d

Manual dev start

  1. Prepare .env.
  2. Install dependencies:
    • powershell ./scripts/bootstrap.ps1
  3. Start infra:
    • docker compose up -d postgres minio
  4. Run migrations:
    • powershell ./scripts/db-migrate.ps1
  5. Optional: load demo catalog data:
    • npm run db:seed
  6. Start services:
    • API: npm run dev:api
    • Web: npm run dev:web

Default admin (bootstrap)

  • Email: admin@example.com
  • Password: Admin123!

Checks

  • npm run lint
  • npm run typecheck
  • npm test
  • npm run build:web
  • npm run build:api