deploy/systemd/: - news-frontend.service (Astro SSR :4321) - news-bridge.service (Fastify :3200) - news-wordpress.service (Docker Compose wrapper) - frontend.env.example + bridge.env.example deploy/nginx/: - newsproject.bitreport.pt.conf (reverse proxy → :4321, /api/ → :3200) - Nginx config validated OK on CT 222 deploy/scripts/: - deploy.sh — full from-scratch deploy (clone, build, install, start) - webhook-deploy.sh — incremental deploy on git push (cron-friendly) Tested on CT 222 (10.10.50.140): - nginx -t → OK - systemd units installed (news-frontend/bridge/wordpress) - news-wordpress enabled; frontend/bridge pending Astro build Remaining manual steps: - DHCP reservation for 10.10.50.140 - NPM proxy host: newsproject.bitreport.pt → http://10.10.50.140 - Run deploy.sh after bridge.env and frontend.env are configured Co-Authored-By: Paperclip <[email protected]> Made-with: Cursor
20 lines
559 B
Bash
20 lines
559 B
Bash
# Fastify Bridge API environment
|
|
# Deploy to /etc/news-platform/bridge.env on the LXC
|
|
# Values are deployment-specific; secrets in vault
|
|
|
|
PORT=3200
|
|
HOST=127.0.0.1
|
|
|
|
# WordPress REST API base URL (Docker, internal)
|
|
WP_API_URL=http://127.0.0.1:8080/wp-json/wp/v2
|
|
|
|
# Redis cache (installed on host)
|
|
REDIS_URL=redis://127.0.0.1:6379
|
|
|
|
# Cache TTL in seconds (default 5 min for articles, 1 min for homepage)
|
|
CACHE_TTL_ARTICLES=300
|
|
CACHE_TTL_HOMEPAGE=60
|
|
|
|
# Domain config path (relative to bridge working directory)
|
|
DOMAIN_CONFIG_DIR=/opt/news-platform/config/domains
|