LOADING…
0%
Complete changelog

Commit

Refactor: Improve Dockerfiles, compose, and auth

Commit details

Commit notes

This commit includes several improvements:

- **Dockerfiles:** Optimized Dockerfiles for both the API and worker, using alpine images and multi-stage builds for smaller image sizes. Added non-root users for enhanced security. - **docker-compose.yml:** Refactored docker-compose to use environment variables for configuration, making it more flexible and secure. Added health checks for all services. - **Auth:** - Implemented secure refresh token generation with a limit per user. - Improved Google OAuth flow to use transactions for user creation/linking and token generation. - Added secure cookie handling for tokens in production and URL parameters in development for OAuth callbacks. - **Error Handling:** Enhanced error handling in the main app to gracefully manage PayloadTooLargeError and RateLimitError. - **Logging:** Improved logging for requests, responses, and errors. - **Rate Limiting:** Integrated a rate limiting middleware. - **CSRF Protection:** Added CSRF protection middleware. - **Database Migrations:** Updated Drizzle metadata to reflect schema changes. - **Queue:** Corrected type parsing for queue job data. - **Redis:** Fixed type inference for rate limiting. - **Admin Routes:** Improved error handling for preview and sequencer generation.

Co-authored-by: armin.naimi <[email redacted]>

Files changed
33
Lines added
+6,674
Lines removed
−3,798
This page is a permanent record of commit 05642e25.