1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mybb_ynh.git synced 2024-09-03 19:46:07 +02:00

pkg_dependencies

This commit is contained in:
ericgaspar 2022-03-12 18:40:42 +01:00
parent f105f69574
commit b46909c34c
No known key found for this signature in database
GPG key ID: 574F281483054D44
5 changed files with 35 additions and 3 deletions

View file

@ -6,7 +6,7 @@
YNH_PHP_VERSION="7.3"
extra_php_dependencies="php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-xml"
pkg_dependencies="php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-xml"
#=================================================
# PERSONAL HELPERS

View file

@ -49,6 +49,13 @@ ynh_script_progression --message="Storing installation settings..." --weight=1
ynh_app_setting_set --app=$app --key=domain --value=$domain
ynh_app_setting_set --app=$app --key=path --value=$path_url
#=================================================
# INSTALL DEPENDENCIES
#=================================================
ynh_script_progression --message="Installing dependencies..." --weight=2
ynh_install_app_dependencies $pkg_dependencies
#=================================================
# CREATE DEDICATED USER
#=================================================
@ -99,7 +106,7 @@ ynh_add_nginx_config
ynh_script_progression --message="Configuring PHP-FPM..." --weight=3
# Create a dedicated PHP-FPM config
ynh_add_fpm_config --package="$extra_php_dependencies"
ynh_add_fpm_config
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================

View file

@ -53,6 +53,14 @@ ynh_script_progression --message="Removing PHP-FPM configuration..." --weight=1
# Remove the dedicated PHP-FPM config
ynh_remove_fpm_config
#=================================================
# REMOVE DEPENDENCIES
#=================================================
ynh_script_progression --message="Removing dependencies..." --weight=2
# Remove metapackage and its dependencies
ynh_remove_app_dependencies
#=================================================
# GENERIC FINALIZATION
#=================================================

View file

@ -74,7 +74,17 @@ ynh_script_progression --message="Restoring the PHP-FPM configuration..." --weig
ynh_restore_file --origin_path="/etc/php/$phpversion/fpm/pool.d/$app.conf"
# Recreate a dedicated php-fpm config
ynh_add_fpm_config --package="$extra_php_dependencies"
ynh_add_fpm_config
#=================================================
# SPECIFIC RESTORATION
#=================================================
# REINSTALL DEPENDENCIES
#=================================================
ynh_script_progression --message="Reinstalling dependencies..." --weight=1
# Define and install dependencies
ynh_install_app_dependencies $pkg_dependencies
#=================================================
# RESTORE THE MYSQL DATABASE

View file

@ -100,6 +100,13 @@ ynh_script_progression --message="Upgrading NGINX web server configuration..." -
# Create a dedicated NGINX config
ynh_add_nginx_config
#=================================================
# UPGRADE DEPENDENCIES
#=================================================
ynh_script_progression --message="Upgrading dependencies..." --weight=2
ynh_install_app_dependencies $pkg_dependencies
#=================================================
# PHP-FPM CONFIGURATION
#=================================================