- Add support for multiple CORS origins (comma-separated)
* Updated src/app.js to parse comma-separated CORS_ORIGIN env variable
* Updated src/server.js to support multiple origins for Socket.io WebSocket connections
* Allows frontend apps from localhost, beta, and production to access the API
- Fix nginx configuration typo preventing HTTPS from working
* Fixed 'body_size_sent' -> 'body_bytes_sent' in log_format
* This typo was preventing nginx from starting with SSL configuration
* Port 443 is now properly listening and accepting HTTPS connections
- Update docker-compose.prod.yml with default CORS origins
* Set default CORS_ORIGIN to include all frontend environments:
- http://localhost:3000 (local development)
- https://beta-app.insightbull.io (beta/staging)
- https://app.insightbull.io (production)
These changes enable:
- Frontend team to access API from all environments (localhost, beta, production)
- HTTPS connections to work properly (port 443)
- WebSocket connections to work from all allowed origins
- Proper CORS headers for cross-origin requests
Fixes connection issues reported by frontend team where:
- CORS was blocking localhost:3000 requests
- HTTPS port 443 was refusing connections
|
||
| 40 | 40 |
|
| 41 | 41 |
|
| 42 | 42 |
|
| 43 |
|
|
| 43 |
|
|
| 44 | 44 |
|
| 45 | 45 |
|
| 46 | 46 |
|
|
||
| 16 | 16 |
|
| 17 | 17 |
|
| 18 | 18 |
|
| 19 |
|
|
| 19 |
|
|
| 20 | 20 |
|
| 21 | 21 |
|
| 22 | 22 |
|
|
||
| 21 | 21 |
|
| 22 | 22 |
|
| 23 | 23 |
|
| 24 |
|
|
| 25 |
|
|
| 26 |
|
|
| 27 |
|
|
| 28 |
|
|
| 24 | 29 |
|
| 25 |
|
|
| 30 |
|
|
| 26 | 31 |
|
| 27 | 32 |
|
| 28 | 33 |
|
|
||
| 16 | 16 |
|
| 17 | 17 |
|
| 18 | 18 |
|
| 19 |
|
|
| 20 |
|
|
| 21 |
|
|
| 22 |
|
|
| 23 |
|
|
| 19 | 24 |
|
| 20 | 25 |
|
| 21 |
|
|
| 26 |
|
|
| 22 | 27 |
|
| 23 | 28 |
|
| 24 | 29 |
|