llm-gateway/start-with-env.sh
Rene Fichtmueller b8543ec191
All checks were successful
changelog-draft / changelog-draft (push) Successful in 31s
feat: proxy subscription clients through gateway
2026-07-18 18:39:18 +02:00

10 lines
456 B
Bash
Executable File

#!/usr/bin/env bash
# PM2 wrapper that ensures defense env is always loaded, even on KeepAlive auto-restart
# Production fix for the recurring PM2 env-drop quirk.
set -a
[ -f /opt/llm-gateway/.env.defense ] && source /opt/llm-gateway/.env.defense
[ -f /opt/llm-gateway/.env.api ] && source /opt/llm-gateway/.env.api
[ -f /opt/llm-gateway/.env ] && source /opt/llm-gateway/.env
set +a
exec /usr/bin/node /opt/llm-gateway/packages/gateway/scripts/launch.mjs