1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gitlab_ynh.git synced 2024-09-03 18:36:35 +02:00

use ynh_check_app_version_changed

This commit is contained in:
kay0u 2019-05-09 10:41:49 +02:00
parent e9c5eee664
commit 7e2ba4785d

View file

@ -33,6 +33,12 @@ unicorn_worker_processes=$(ynh_app_setting_get --app="$app" --key=unicorn_worker
client_max_body_size=$(ynh_app_setting_get --app="$app" --key=client_max_body_size)
overwrite_nginx=$(ynh_app_setting_get --app="$app" --key=overwrite_nginx)
#=================================================
# CHECK VERSION
#=================================================
upgrade_type=$(ynh_check_app_version_changed)
#=================================================
# ENSURE DOWNWARD COMPATIBILITY
#=================================================
@ -202,7 +208,6 @@ chown admin: "$config_path/gitlab-persistent.rb"
#=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE
#=================================================
ynh_script_progression --message="Setting up source files..." --weight=690
update_src_version() {
source ./upgrade.d/upgrade.last.sh
@ -217,6 +222,10 @@ update_src_version() {
fi
}
if [ "$upgrade_type" == "UPGRADE_APP" ]
then
ynh_script_progression --message="Setting up source files..." --weight=690
update_src_version
tempdir="$(mktemp -d)"
@ -232,6 +241,9 @@ else
ynh_exec_warn_less dpkg -i $tempdir/$gitlab_filename
fi
ynh_exec_warn_less ynh_secure_remove --file="$tempdir"
fi
#=================================================
# NGINX CONFIGURATION
#=================================================