0
Fork 0
mirror of https://github.com/stonith404/pingvin-share.git synced 2025-02-05 01:38:56 -05:00
pingvin-share/scripts/docker/entrypoint.sh

21 lines
534 B
Bash
Raw Normal View History

#!/bin/sh
# Copy default logo to the frontend public folder if it doesn't exist
cp -rn /tmp/img/* /opt/app/frontend/public/img
# Start Caddy
if [ "$TRUST_PROXY" = "true" ]; then
2024-12-24 16:06:59 +01:00
caddy start --adapter caddyfile --config /opt/app/reverse-proxy/Caddyfile.trust-proxy &
else
2024-12-24 16:06:59 +01:00
caddy start --adapter caddyfile --config /opt/app/reverse-proxy/Caddyfile &
fi
# Run the frontend server
PORT=3333 HOSTNAME=0.0.0.0 node frontend/server.js &
# Run the backend server
cd backend && npm run prod
# Wait for all processes to finish
wait -n