Allow all origins by default, restrict only when ALLOWED_ORIGINS is set
Same-origin requests don't need CORS restrictions. Users can optionally set ALLOWED_ORIGINS to lock it down.
This commit is contained in:
@@ -7,7 +7,7 @@ services:
|
||||
environment:
|
||||
- NODE_ENV=production
|
||||
- JWT_SECRET=${JWT_SECRET:-change-me-to-a-long-random-string}
|
||||
- ALLOWED_ORIGINS=${ALLOWED_ORIGINS:-http://localhost:3000}
|
||||
# - ALLOWED_ORIGINS=https://yourdomain.com # Optional: restrict CORS to specific origins
|
||||
- PORT=3000
|
||||
volumes:
|
||||
- ./data:/app/data
|
||||
|
||||
Reference in New Issue
Block a user