diff options
Diffstat (limited to 'entrypoint.sh')
-rwxr-xr-x | entrypoint.sh | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/entrypoint.sh b/entrypoint.sh new file mode 100755 index 0000000..5bdcede --- /dev/null +++ b/entrypoint.sh @@ -0,0 +1,15 @@ +#!/bin/sh + +set -e + +echo "Starting fcgiwrap..." +su -l www-data -s /bin/bash -c "/usr/sbin/fcgiwrap -s unix:/run/sock/fcgiwrap.socket" & + +echo "Waiting for fcgiwrap socket to appear..." +while [ ! -S /run/sock/fcgiwrap.socket ]; do + sleep 0.1 +done +echo "fcgiwrap socket found." + +echo "Starting Nginx..." +exec nginx -g 'daemon off;' |