From 2017bf1f7915f8a8d171749c2e539b1e5d30bdbe Mon Sep 17 00:00:00 2001 From: yalh76 Date: Fri, 10 Jun 2022 13:11:31 +0200 Subject: [PATCH] Apply last example_ynh --- scripts/_common.sh | 6 ++---- scripts/install | 16 ++++++++-------- 2 files changed, 10 insertions(+), 12 deletions(-) diff --git a/scripts/_common.sh b/scripts/_common.sh index ecc0e7e..11dd26b 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -5,11 +5,9 @@ #================================================= # dependencies used by the app -YNH_PHP_VERSION="7.4" +pkg_dependencies="php$YNH_DEFAULT_PHP_VERSION-tidy php$YNH_DEFAULT_PHP_VERSION-intl php$YNH_DEFAULT_PHP_VERSION-mbstring php$YNH_DEFAULT_PHP_VERSION-xml php$YNH_DEFAULT_PHP_VERSION-gd php$YNH_DEFAULT_PHP_VERSION-curl php$YNH_DEFAULT_PHP_VERSION-mysql" -pkg_dependencies="php${YNH_PHP_VERSION}-tidy php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-mbstring php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-mysql" - -pgsql_pkg_dependencies="postgresql php${YNH_PHP_VERSION}-pgsql" +pgsql_pkg_dependencies="postgresql php$YNH_DEFAULT_PHP_VERSION-pgsql" #================================================= # PERSONAL HELPERS diff --git a/scripts/install b/scripts/install index 9c37ecc..12cfc9c 100644 --- a/scripts/install +++ b/scripts/install @@ -105,14 +105,6 @@ chmod 750 "$final_path" chmod -R o-rwx "$final_path" chown -R $app:www-data "$final_path" -#================================================= -# NGINX CONFIGURATION -#================================================= -ynh_script_progression --message="Configuring NGINX web server..." --weight=1 - -# Create a dedicated NGINX config -ynh_add_nginx_config - #================================================= # PHP-FPM CONFIGURATION #================================================= @@ -122,6 +114,14 @@ ynh_script_progression --message="Configuring PHP-FPM..." --weight=2 ynh_add_fpm_config phpversion=$(ynh_app_setting_get --app=$app --key=phpversion) +#================================================= +# NGINX CONFIGURATION +#================================================= +ynh_script_progression --message="Configuring NGINX web server..." --weight=1 + +# Create a dedicated NGINX config +ynh_add_nginx_config + #================================================= # SPECIFIC SETUP #=================================================