fix: harden server per final review
- load static files at startup so a missing file fails fast instead of crashing on request - WAL + busy_timeout so a manual export cannot fail live submissions - exit cleanly on SIGTERM (node is PID 1 in the container) - honour PORT=0 - document a required ingress rate limit - square card corners and larger card titles Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EFUzfmHGGiYUjNcvJoyzdf
This commit is contained in:
1 parent
c98c6da2ab
commit
f75da6d928
4 files changed
+57
-15
No files matched your search
@@ -29,6 +29,7 @@ docker run -p 3000:3000 -v ins-leads:/data ins-landing-page
|
||||
- Run exactly **1 replica** (SQLite file, single writer). Use `strategy: Recreate` so two pods never hold the volume at once during a rollout.
|
||||
- The container runs as user `node` (uid 1000); set `securityContext.fsGroup: 1000` so it can write to the volume.
|
||||
- Health check: `GET /` returns 200.
|
||||
- **Required: rate-limit `POST /api/leads` at the ingress.** The form is public and the honeypot only stops naive bots; without a limit a script can fill the volume. For ingress-nginx, e.g. `nginx.ingress.kubernetes.io/limit-rpm: "30"` (per client IP, applies to the whole Ingress) on this Ingress.
|
||||
|
||||
## Exporting leads
|
||||
|
||||
|
||||
Reference in new issue
Block a user