From dafc6a75871a642ed81c7c790999f4e2d0d69199 Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Mon, 3 Aug 2020 13:51:46 +0200 Subject: [PATCH] Update install --- scripts/install | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/scripts/install b/scripts/install index 4e17ed9..e28333d 100644 --- a/scripts/install +++ b/scripts/install @@ -122,11 +122,10 @@ ynh_script_progression --message="Configuring php-fpm..." --time --weight=1 # Create a dedicated php-fpm config #ynh_replace_string --match_string="YHTZ" --replace_string="$timezone" --target_file=../conf/php-fpm.conf +phpversion=$(ynh_app_setting_get --app="$app" --key=phpversion) ynh_add_fpm_config --package="$extra_php_dependencies" -phpversion=$(ynh_app_setting_get --app="$app" --key=phpversion) - #================================================= # SET CONFIGURATION FILE #================================================= @@ -144,14 +143,22 @@ ynh_store_file_checksum --file="$final_path/config/db.inc.php" # Install PHP dependencies using composer #================================================= -pushd "$final_path" || ynh_die -export COMPOSER_HOME=$final_path +# pushd "$final_path" || ynh_die +# export COMPOSER_HOME=$final_path +# curl -sS https://getcomposer.org/installer | php -- --install-dir="$final_path" \ +# && php composer.phar config --global discard-changes true --quiet \ +# && php composer.phar install --no-interaction --quiet +# #sudo -u www-data php composer.phar install +# #sudo -u www-data php composer.phar $app:migrate +# popd || ynh_die + +( + cd "$final_path" + export COMPOSER_HOME=$final_path curl -sS https://getcomposer.org/installer | php -- --install-dir="$final_path" \ - && php composer.phar config --global discard-changes true --quiet \ - && php composer.phar install --no-interaction --quiet - #sudo -u www-data php composer.phar install - #sudo -u www-data php composer.phar $app:migrate -popd || ynh_die + && php composer.phar config --global discard-changes true --quiet \ + && php composer.phar install --no-interaction --quiet +) #================================================= # SETUP SYSTEMD