From 27fed044ccd200d4e791af2c141a8e77b2fc9b68 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Thu, 20 Jun 2024 23:31:09 +0200 Subject: [PATCH] Fix upgrade: app_path instead of install_dir --- scripts/upgrade | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 1b3150c..ce7ab03 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -3,6 +3,8 @@ source _common.sh source /usr/share/yunohost/helpers +app_path="$install_dir/go/src/github.com/georgyo/ifconfig.io" + #================================================= # UPGRADE DEPENDENCIES #================================================= @@ -24,7 +26,7 @@ ynh_systemd_action --service_name=$app --action="stop" --log_path="/var/log/$app #================================================= ynh_script_progression --message="Upgrading source files..." --weight=1 -ynh_setup_source --dest_dir="$install_dir" --full_replace=1 +ynh_setup_source --dest_dir="$app_path" --full_replace=1 chmod -R o-rwx "$install_dir" chown -R $app:www-data "$install_dir" @@ -39,7 +41,7 @@ export GOPATH="$install_dir/go" export GOCACHE="$install_dir/go/.cache" export GO111MODULE=on -pushd "$install_dir" +pushd "$app_path" ynh_exec_warn_less $ynh_go mod download ynh_exec_warn_less $ynh_go build -tags=jsoniter popd