From 316993476947c758e4c4107f4fca5fc47158cac8 Mon Sep 17 00:00:00 2001 From: FusionPBX Date: Sun, 17 Feb 2019 08:32:54 -0700 Subject: [PATCH] Update php.sh --- debian/resources/php.sh | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/debian/resources/php.sh b/debian/resources/php.sh index 570ee5d..53707db 100755 --- a/debian/resources/php.sh +++ b/debian/resources/php.sh @@ -15,11 +15,25 @@ verbose "Configuring PHP" if [ ."$os_codename" = ."stretch" ]; then if [ ."$cpu_architecture" = ."arm" ]; then php_version=7.2 - else - php_version=7.0 fi fi +#install dependencies +apt-get install -y nginx +if [ ."$php_version" = ."5.6" ]; then + apt-get install -y php5 php5-cli php5-fpm php5-pgsql php5-sqlite php5-odbc php5-curl php5-imap php5-mcrypt php5-gd +fi +if [ ."$php_version" = ."7.0" ]; then + apt-get install -y php7.0 php7.0-cli php7.0-fpm php7.0-pgsql php7.0-sqlite3 php7.0-odbc php7.0-curl php7.0-imap php7.0-mcrypt php7.0-xml php7.0-gd +fi +if [ ."$php_version" = ."7.1" ]; then + apt-get install -y php7.1 php7.1-cli php7.1-fpm php7.1-pgsql php7.1-sqlite3 php7.1-odbc php7.1-curl php7.1-imap php7.1-mcrypt php7.1-xml php7.1-gd +fi +if [ ."$php_version" = ."7.2" ]; then + apt-get install -y php7.2 php7.2-cli php7.2-fpm php7.2-pgsql php7.2-sqlite3 php7.2-odbc php7.2-curl php7.2-imap php7.2-xml php7.2-gd + apt-get install -y php7.2-mcrypt +fi + #update config if source is being used if [ ."$php_version" = ."5" ]; then verbose "version 5.x"