1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/matomo_ynh.git synced 2024-09-03 19:45:56 +02:00

set core:upgrade

This commit is contained in:
ericgaspar 2021-06-29 13:40:44 +02:00
parent 6bc6c6439c
commit 8160a44605
No known key found for this signature in database
GPG key ID: 574F281483054D44
4 changed files with 12 additions and 18 deletions

View file

@ -1,6 +0,0 @@
SOURCE_URL=https://github.com/matomo-org/matomo-icons/archive/e96ef33bf490794829831cbb795fd4ea67259699.tar.gz
SOURCE_SUM=9a6457d8f138216f911621db7a5af5fbce7214e62d6f184730f216986e498b53
SOURCE_SUM_PRG=sha256sum
SOURCE_FORMAT=tar.gz
SOURCE_IN_SUBDIR=true
SOURCE_FILENAME=

View file

@ -8,9 +8,6 @@ YNH_PHP_VERSION="7.3"
extra_php_dependencies="php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-cli php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-mbstring"
# Composer version
YNH_COMPOSER_VERSION="2.0.13"
#=================================================
# PERSONAL HELPERS
#=================================================

View file

@ -94,10 +94,6 @@ ynh_script_progression --message="Configuring PHP-FPM..."
ynh_add_fpm_config --usage=low --footprint=low --package="$extra_php_dependencies"
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
#=================================================
# SPECIFIC SETUP
#=================================================
#=================================================
# SETUP A CRON
#=================================================

View file

@ -91,8 +91,19 @@ then
# This condition is only for CI test to go through the upgrade process
ynh_setup_source --dest_dir="$final_path"
else
# Create a temporary directory
tmpdir="$(mktemp -d)"
cp -a "$final_path/config/config.ini.php" "$tmpdir/config.ini.php"
# Remove the app directory securely
ynh_secure_remove --file=$final_path
# Download, check integrity, uncompress and patch the source from app.src
ynh_setup_source --dest_dir="$final_path" --keep="$final_path/config/config.ini.php"
ynh_setup_source --dest_dir="$final_path"
cp -a "$tmpdir/config_inc.php" "$final_path/config/config_inc.php"
# Remove the tmp directory securely
ynh_secure_remove --file="$tmpdir"
php$phpversion $final_path/console core:update -n
fi
fi
@ -116,10 +127,6 @@ ynh_script_progression --message="Upgrading PHP-FPM configuration..."
# Create a dedicated PHP-FPM config
ynh_add_fpm_config --usage=low --footprint=low --package="$extra_php_dependencies"
#=================================================
# SPECIFIC UPGRADE
#=================================================
#=================================================
# SETUP A CRON
#=================================================