php7: add new package

This is a copy of the existing php5 stuff, adopted for PHP7.

Please not, that its not supported to install both php5
and php7 in parallel on the target.

Signed-off-by: Michael Heimpold <mhei@heimpold.de>
This commit is contained in:
Michael Heimpold
2016-07-18 23:30:38 +02:00
parent 1034356e9e
commit 292c2ffc18
13 changed files with 1770 additions and 0 deletions
+29
View File
@@ -0,0 +1,29 @@
#!/bin/sh /etc/rc.common
START=50
SERVICE_DAEMONIZE=1
SERVICE_WRITE_PID=1
start_instance() {
local section="$1"
local enabled
local port
config_get_bool enabled "$section" 'enabled' 0
config_get port "$section" 'port' 1026
[ $enabled -gt 0 ] || return 1
PHP_FCGI_CHILDREN='' \
service_start /usr/bin/php-fcgi -b $port
}
start() {
config_load 'php7-fastcgi'
config_foreach start_instance 'php7-fastcgi'
}
stop() {
service_stop /usr/bin/php-fcgi
}