Shira is a Turborepo monorepo with a NestJS API, a public-facing quiz app, an internal spaces app, and shared packages used across the workspace.
apps/api: NestJS backend for auth, quizzes, learners, subscriptions, email, and integrations.apps/public: Public quiz experience for learners and invite flows.apps/spaces: Internal product for managing quizzes, questions, learners, and organizations.packages/shira-ui: Shared UI components used by the frontend apps.
- Node.js and npm installed
- Docker and Docker Compose installed
Copy the app env files before starting:
cp apps/api/.env.example apps/api/.env
cp apps/public/.env.example apps/public/.env
cp apps/spaces/.env.example apps/spaces/.envSet ENABLE_PUBLIC_LIBRARY=false in apps/api/.env to disable the public quiz library on self-hosted instances that don't want to depend on the public library service.
- Install dependencies from the repo root:
npm install- Create the shared Docker network once:
docker network create shira-network- Start MySQL and Redis for the API:
docker compose -f apps/api/docker-compose.required.yml up -d- Start the workspace from the repo root:
npm run devDon't forget to build from root if you made changes in the shira-ui package:
npm run build- You can also run Storybook from
packages/shira-ui:
cd packages/shira-ui
npm run storybookThis starts:
- API on
http://localhost:3000 - Public app on
http://localhost:3001 - Spaces app on
http://localhost:3002
Run API migrations from apps/api after the backend is up:
cd apps/api
npm run typeorm -- migration:run -d ./src/utils/datasources/mysql.datasource.ts