chore: make Docker image run without root user (#67)

This commit is contained in:
Elias Schneider
2024-11-21 18:44:43 +01:00
committed by GitHub
parent e784093342
commit 46eef1fcb7
4 changed files with 35 additions and 3 deletions

View File

@@ -0,0 +1,16 @@
echo "Starting frontend..."
node frontend/build &
echo "Starting backend..."
cd backend && ./pocket-id-backend &
echo "Starting Caddy..."
# Check if TRUST_PROXY is set to true and use the appropriate Caddyfile
if [ "$TRUST_PROXY" = "true" ]; then
caddy start --config /etc/caddy/Caddyfile.trust-proxy &
else
caddy start --config /etc/caddy/Caddyfile &
fi
wait