Spaces:
Running
Running
docs: add production deployment gates
Browse files- DEPLOYMENT_RUNBOOK.md +25 -0
DEPLOYMENT_RUNBOOK.md
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# Production deployment runbook
|
| 2 |
+
|
| 3 |
+
## Required before enabling public access
|
| 4 |
+
|
| 5 |
+
1. Set `GITHUB_TOKEN` or configure the GitHub App/OAuth flow.
|
| 6 |
+
2. Set one remote inference credential (`GEMINI_API_KEY`, `GROQ_API_KEY`, or a configured endpoint).
|
| 7 |
+
3. Set `OCR_REQUIRE_AUTH=true` and a strong `OCR_API_KEY` until web OAuth is enabled.
|
| 8 |
+
4. Set `OCR_ALLOWED_ORIGINS` to the exact Vercel origin.
|
| 9 |
+
5. Set `OPENCODEREVIEW_DB_PATH` to a mounted persistent path, or migrate the
|
| 10 |
+
job/checkpoint store to Postgres before running more than one replica.
|
| 11 |
+
6. Keep `OPENCODEREVIEW_ALLOW_LOCAL_EMBEDDINGS=false` on small hosts.
|
| 12 |
+
|
| 13 |
+
## Verification gates
|
| 14 |
+
|
| 15 |
+
- `GET /api/health` reports `remote_provider_configured` and `configured_path`.
|
| 16 |
+
- A real PR reaches `awaiting_approval` without posting comments automatically.
|
| 17 |
+
- The decision endpoint returns a structured posting receipt.
|
| 18 |
+
- RAGAS reaches `completed` with non-empty metric values, or reports a bounded
|
| 19 |
+
terminal failure with an actionable reason.
|
| 20 |
+
- Restart the worker and confirm an awaiting-approval job remains readable.
|
| 21 |
+
- Run the offline Code Review Bench scorer and retain its JSON result artifact.
|
| 22 |
+
|
| 23 |
+
The current Hugging Face Space passes the health and live-review gates, but its
|
| 24 |
+
default filesystem is ephemeral. Configure persistent storage before claiming
|
| 25 |
+
restart-safe production durability.
|