diff options
author | Ermal <eri@pfsense.org> | 2014-10-06 18:05:50 +0200 |
---|---|---|
committer | Ermal <eri@pfsense.org> | 2014-10-06 18:05:50 +0200 |
commit | a3cc8dcc600d105d73eb4729c32433d40d72cab7 (patch) | |
tree | 91322dd4fc8973aa44f303ccd4ed8686bd97163c /etc/rc.php-fpm_restart | |
parent | 9c2968266996b21bb4e3754ae7ae4d6100970563 (diff) | |
download | pfsense-a3cc8dcc600d105d73eb4729c32433d40d72cab7.zip pfsense-a3cc8dcc600d105d73eb4729c32433d40d72cab7.tar.gz |
Add an option to restart php-fpm from console
Diffstat (limited to 'etc/rc.php-fpm_restart')
-rwxr-xr-x | etc/rc.php-fpm_restart | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/etc/rc.php-fpm_restart b/etc/rc.php-fpm_restart new file mode 100755 index 0000000..422b951 --- /dev/null +++ b/etc/rc.php-fpm_restart @@ -0,0 +1,11 @@ +#!/bin/sh + +/bin/pkill -F /var/run/php-fpm.pid +sleep 2 + +# Run the php.ini setup file and populate +# /usr/local/etc/php.ini and /usr/local/lib/php.ini +/etc/rc.php_ini_setup 2>/tmp/php_errors.txt +echo ">>> Restarting php-fpm" | /usr/bin/logger -p daemon.info -i -t rc.php-fpm_restart +/usr/local/sbin/php-fpm -c /usr/local/lib/php.ini -y /usr/local/lib/php-fpm.conf -RD 2>&1 >/dev/null + |