mirror of
https://github.com/YunoHost-Apps/wekan_ynh.git
synced 2024-09-03 20:36:09 +02:00
Fix upgrade
This commit is contained in:
parent
10b14700d8
commit
dccac47828
3 changed files with 6 additions and 1 deletions
|
@ -20,6 +20,9 @@ old_path=$YNH_APP_OLD_PATH
|
|||
new_domain=$YNH_APP_NEW_DOMAIN
|
||||
new_path=$YNH_APP_NEW_PATH
|
||||
|
||||
db_name=$(ynh_app_setting_get $app db_name)
|
||||
port=$(ynh_app_setting_get $app port)
|
||||
|
||||
app=$YNH_APP_INSTANCE_NAME
|
||||
|
||||
#=================================================
|
||||
|
@ -98,12 +101,12 @@ fi
|
|||
ynh_print_info "Updating .env configuration..."
|
||||
|
||||
ynh_systemd_action --action=stop --service_name=$app --log_path="systemd"
|
||||
ynh_use_nodejs
|
||||
ynh_replace_string "__NODEJS_PATH__" "$nodejs_path" "$final_path/.env"
|
||||
ynh_replace_string "__DB_NAME__" "$db_name" "$final_path/.env"
|
||||
ynh_replace_string "__DOMAIN_URI__" "$new_domain$new_path" "$final_path/.env"
|
||||
ynh_replace_string "__PORT__" "$port" "$final_path/.env"
|
||||
ynh_systemd_action --action=start --service_name=$app --log_path="systemd" --line_match="Kadira: completed instrumenting the app"
|
||||
sleep 10
|
||||
|
||||
#=================================================
|
||||
# GENERIC FINALISATION
|
||||
|
|
|
@ -101,6 +101,7 @@ ynh_print_info "Installing dependencies..."
|
|||
|
||||
ynh_print_info "Installing nodejs ..."
|
||||
ynh_install_nodejs 8.15.1
|
||||
ynh_use_nodejs
|
||||
|
||||
ynh_print_info "Installing mongodb dependencies ..."
|
||||
ynh_install_app_dependencies "mongodb mongodb-server"
|
||||
|
|
|
@ -86,6 +86,7 @@ ynh_print_info "Reinstalling dependencies..."
|
|||
|
||||
# Define and install dependencies
|
||||
ynh_install_nodejs 8.15.1
|
||||
ynh_use_nodejs
|
||||
|
||||
# Install mongodb
|
||||
ynh_install_app_dependencies "mongodb mongodb-server"
|
||||
|
|
Loading…
Reference in a new issue