Repository navigation
Expand file tree
/
Copy pathrender.yaml
More file actions
90 lines (89 loc) · 3.51 KB
/
Copy pathrender.yaml
File metadata and controls
90 lines (89 loc) · 3.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
services:
# ── Backend — FastAPI ─────────────────────────────────────────────────────
- type: web
name: video-magic-api
runtime: python
region: oregon
plan: starter # 512 MB RAM — Veo polling is pure I/O; ffmpeg peaks ~250 MB
# Upgrade to standard ($25) only if ffmpeg OOMs on 60s videos
buildCommand: "pip install -r backend/requirements.txt"
startCommand: "cd backend && uvicorn main:app --host 0.0.0.0 --port $PORT"
rootDir: .
healthCheckPath: /health
envVars:
- key: RENDER_PYTHON_VERSION
value: "3.12.0"
- key: GEMINI_API_KEY
sync: false # set in Render dashboard
- key: ELEVENLABS_API_KEY
sync: false
- key: ELEVENLABS_VOICE_ID
value: nPczCjzI2devNBz1zQrb
- key: STRIPE_SECRET_KEY
sync: false
- key: STRIPE_WEBHOOK_SECRET
sync: false
- key: BACKEND_PROXY_SECRET
generateValue: true # shared with the frontend below via fromService.
# The API trusts X-User-Id only when this matches,
# and refuses every guarded route if it is unset.
- key: STRIPE_PRICE_10S
sync: false
- key: STRIPE_PRICE_30S
sync: false
- key: STRIPE_PRICE_60S
sync: false
- key: APP_URL
value: https://videomagic.servicevision.io
- key: CORS_ORIGINS
value: https://videomagic.servicevision.io
- key: STORAGE_DIR
value: /opt/render/project/storage/projects
- key: DATABASE_PATH
value: /opt/render/project/storage/video_magic.db
- key: VIDEO_TAIL_SILENCE_S
value: "1.5" # seconds of freeze-frame + silence after narrator finishes
- key: GEMINI_FLASH_MODEL
value: AUTO # AUTO = auto-select from fallback chain; set a model name to pin
- key: IMAGEN_MODEL
value: AUTO
- key: VEO_MODEL
value: AUTO
disk:
name: video-magic-storage
mountPath: /opt/render/project/storage
sizeGB: 1 # 1 GB at $0.25/mo — holds ~20 test videos; scale when needed
# ── Frontend — Next.js ────────────────────────────────────────────────────
- type: web
name: video-magic-frontend
runtime: node
region: oregon
plan: starter # 512 MB RAM — Next.js SSR is fine at this scale
rootDir: frontend
buildCommand: "npm install && npm run build"
startCommand: "npm start"
healthCheckPath: /
envVars:
- key: NODE_ENV
value: production
- key: BACKEND_URL
sync: false # set in Render dashboard to https://<video-magic-api>.onrender.com
- key: NEXT_PUBLIC_BACKEND_URL
sync: false # same value as BACKEND_URL
- key: BACKEND_PROXY_SECRET
fromService:
name: video-magic-api
type: web
envVarKey: BACKEND_PROXY_SECRET
- key: NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY
sync: false
- key: CLERK_SECRET_KEY
sync: false
- key: NEXT_PUBLIC_CLERK_SIGN_IN_URL
value: /sign-in
- key: NEXT_PUBLIC_CLERK_SIGN_UP_URL
value: /sign-up
- key: NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL
value: /create
- key: NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL
value: /create