- Source role and project_id from users table in auth flow
- Update UserRow interface to include role and project_id fields
- Update schema.sql to add role and project_id columns to users table
- Remove dotenv import from server/src/index.ts
- Trim auth.test.ts to only required test case
- Update auth route to use database values instead of hardcoded
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Use Zod v4 'issues' property instead of 'errors' in env.ts
- Integrate database pool cleanup in graceful shutdown
- Increase users.password_hash to VARCHAR(512) for future-proofing
- Add updated_at column to oss_files table
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Add .env.example with PORT, MySQL, JWT, and OSS configuration
- Create schema.sql with users, projects, oss_files, and hazards tables
- Implement env.ts with Zod-based environment variable parsing
- Implement db.ts with MySQL connection pool using mysql2/promise
- Update /health endpoint to return service metadata
- Update health test to verify service name
- Install zod and mysql2 dependencies
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>