Add Docker + nginx deployment for homelab
- Multi-stage Dockerfile: Node builds static assets, nginx serves them - nginx proxies /api/* to football-data.org and injects X-Auth-Token server-side via FOOTBALL_API_KEY env var (key never in browser bundle) - docker-compose.yml exposes the app on port 3000 - Extract apiFetch() helper: sends key in dev (Vite proxy), skips in prod - .env.example updated with both dev and production key vars Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1 +1,5 @@
|
||||
# Used by docker-compose (nginx injects it server-side — never exposed to browser)
|
||||
FOOTBALL_API_KEY=your_api_key_here
|
||||
|
||||
# Only needed for local development (npm run dev)
|
||||
VITE_FOOTBALL_API_KEY=your_api_key_here
|
||||
|
||||
Reference in New Issue
Block a user