mirror of
https://github.com/YunoHost-Apps/cryptpad_ynh.git
synced 2024-09-03 18:26:14 +02:00
fix incorrect yunohost function calls (#36)
* [scripts][upgrade] fix nginx config yunohost helper function call * [scripts][upgrade] fix backup after failed upgrade yunohost helper function call * [scripts] fix deprecated variable use - nodejs_version * [scripts][upgrade] fix systemd config yunohost helper function call
This commit is contained in:
parent
e1088215f5
commit
bb0718550a
2 changed files with 5 additions and 5 deletions
|
@ -103,7 +103,7 @@ ynh_add_nginx_config
|
|||
|
||||
# Create a dedicated systemd config
|
||||
ynh_add_systemd_config
|
||||
ynh_replace_string "__NODEJS__" "$nodejs_use_version" "/etc/systemd/system/$app.service"
|
||||
ynh_replace_string "__NODEJS__" "$nodejs_version" "/etc/systemd/system/$app.service"
|
||||
ynh_replace_string "__ENV_PATH__" "$PATH" "/etc/systemd/system/$app.service"
|
||||
ynh_replace_string "__NODE__" "$nodejs_path" "/etc/systemd/system/$app.service"
|
||||
systemctl daemon-reload
|
||||
|
|
|
@ -39,7 +39,7 @@ port=$(ynh_app_setting_get "$app" port)
|
|||
if [ -f "/etc/yunohost/apps/$app/scripts/backup" ] ; then
|
||||
ynh_backup_before_upgrade # Backup the current version of the app
|
||||
ynh_clean_setup () {
|
||||
ynh_backup_after_failed_upgrade
|
||||
ynh_restore_upgradebackup
|
||||
}
|
||||
ynh_abort_if_errors # Stop script if an error is detected
|
||||
fi
|
||||
|
@ -80,16 +80,16 @@ sudo chmod 755 $final_path -R
|
|||
# Modify Nginx configuration file and copy it to Nginx conf directory
|
||||
#=================================================
|
||||
|
||||
ynh_nginx_config
|
||||
ynh_add_nginx_config
|
||||
|
||||
#=================================================
|
||||
# ADD SYSTEMD SERVICE
|
||||
#=================================================
|
||||
|
||||
ynh_replace_string "__NODE__" "$nodejs_path" "../conf/systemd.service"
|
||||
ynh_replace_string "__NODEJS__" "$nodejs_use_version" "../conf/systemd.service"
|
||||
ynh_replace_string "__NODEJS__" "$nodejs_version" "../conf/systemd.service"
|
||||
ynh_replace_string "__ENV_PATH__" "$PATH" "../conf/systemd.service"
|
||||
ynh_systemd_config
|
||||
ynh_add_systemd_config
|
||||
|
||||
|
||||
#=================================================
|
||||
|
|
Loading…
Reference in a new issue