🔧
This commit is contained in:
11
vendor/laravel/sail/runtimes/8.2/start-container
vendored
11
vendor/laravel/sail/runtimes/8.2/start-container
vendored
@@ -1,5 +1,10 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if [ "$SUPERVISOR_PHP_USER" != "root" ] && [ "$SUPERVISOR_PHP_USER" != "sail" ]; then
|
||||
echo "You should set SUPERVISOR_PHP_USER to either 'sail' or 'root'."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -z "$WWWUSER" ]; then
|
||||
usermod -u $WWWUSER sail
|
||||
fi
|
||||
@@ -11,7 +16,11 @@ fi
|
||||
chmod -R ugo+rw /.composer
|
||||
|
||||
if [ $# -gt 0 ]; then
|
||||
exec gosu $WWWUSER "$@"
|
||||
if [ "$SUPERVISOR_PHP_USER" = "root" ]; then
|
||||
exec "$@"
|
||||
else
|
||||
exec gosu $WWWUSER "$@"
|
||||
fi
|
||||
else
|
||||
exec /usr/bin/supervisord -c /etc/supervisor/conf.d/supervisord.conf
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user