Skip to content

Commit 843a608

Browse files
committed
feat: update CORS origins and API request limits in Terraform configuration
1 parent 5221fe1 commit 843a608

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

infrastructure/terraform/prod.tfvars

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,15 @@ ec2_volume_size = 50
3434
# Max build time before instance self-terminates (safety net)
3535
ec2_max_build_time_minutes = 30
3636

37-
# CORS origins - restrict to your GitHub Pages URL in production
37+
# CORS origins - MUST be restricted to your GitHub Pages URL in production.
38+
# Using ["*"] exposes the API to cross-origin requests from any website.
3839
# Example: ["https://yourusername.github.io"]
39-
allowed_origins = ["*"]
40+
# allowed_origins = ["https://yourusername.github.io"]
41+
allowed_origins = ["https://fok666.github.io"] # TODO: replace with your actual frontend origin
4042

41-
# API request limits
42-
# api_throttle_rate = 10
43-
# api_throttle_burst = 20
43+
# API request limits (per-stage; tune down for tighter abuse prevention)
44+
api_throttle_rate = 5 # requests per second
45+
api_throttle_burst = 10 # burst limit
46+
47+
# Maximum concurrent builds (each may launch up to 2 EC2 Spot instances)
48+
max_active_builds = 10

0 commit comments

Comments
 (0)