mirror of
https://github.com/aljazceru/cyphernode.git
synced 2025-12-17 12:45:22 +01:00
17 lines
423 B
Bash
17 lines
423 B
Bash
#!/bin/sh
|
|
|
|
while [ ! -f "/container_monitor/proxy_ready" ]; do echo "proxy not ready" ; sleep 10 ; done
|
|
|
|
echo "proxy ready"
|
|
|
|
if [ -n "$1" ]; then
|
|
user=$(echo "$1" | cut -d ':' -f 1)
|
|
else
|
|
user='nginx'
|
|
fi
|
|
|
|
spawn-fcgi -M 0660 -s /var/run/fcgiwrap.socket -u $user -g nginx -U $user -- `which fcgiwrap`
|
|
chmod -R g+rw /var/run/fcgiwrap.socket /etc/nginx/conf.d/*
|
|
chown -R :nginx /etc/nginx/conf.d/*
|
|
exec nginx -g "daemon off;"
|