mirror of
https://github.com/YunoHost-Apps/diaspora_ynh.git
synced 2024-09-03 18:26:13 +02:00
Update upgrade
This commit is contained in:
parent
5c9d698dd8
commit
28f3443c68
1 changed files with 11 additions and 10 deletions
|
@ -85,6 +85,14 @@ if gpg --list-keys piotr.kuczynski@gmail.com >/dev/null 2>&1; then
|
||||||
ynh_secure_remove "$final_path/piotr.kuczynski@gmail.com.pgp"
|
ynh_secure_remove "$final_path/piotr.kuczynski@gmail.com.pgp"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ -d "$final_path/live" ]; then
|
||||||
|
ynh_delete_file_checksum --file="$final_path/diaspora/config/diaspora.yml"
|
||||||
|
ynh_delete_file_checksum --file="$final_path/diaspora/config/database.yml"
|
||||||
|
mv "$final_path/diaspora" "$final_path/live"
|
||||||
|
ynh_store_file_checksum --file="$final_path/live/config/diaspora.yml"
|
||||||
|
ynh_store_file_checksum --file="$final_path/live/config/database.yml"
|
||||||
|
fi
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# CREATE DEDICATED USER
|
# CREATE DEDICATED USER
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -102,7 +110,7 @@ then
|
||||||
ynh_script_progression --message="Upgrading source files..."
|
ynh_script_progression --message="Upgrading source files..."
|
||||||
|
|
||||||
# Download, check integrity, uncompress and patch the source from app.src
|
# Download, check integrity, uncompress and patch the source from app.src
|
||||||
ynh_setup_source --dest_dir="$final_path/live"
|
ynh_setup_source --dest_dir="$final_path/live" --keep="live/config/diaspora.yml live/config/database.yml"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
chmod 750 "$final_path"
|
chmod 750 "$final_path"
|
||||||
|
@ -126,7 +134,6 @@ ynh_exec_warn_less ynh_install_app_dependencies $pkg_dependencies $build_pkg_dep
|
||||||
ynh_exec_warn_less ynh_install_ruby --ruby_version=$ruby_version
|
ynh_exec_warn_less ynh_install_ruby --ruby_version=$ruby_version
|
||||||
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
ynh_exec_warn_less ynh_install_nodejs --nodejs_version=$nodejs_version
|
||||||
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# SPECIFIC UPGRADE
|
# SPECIFIC UPGRADE
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -196,14 +203,8 @@ yunohost service add $app.target \
|
||||||
ynh_script_progression --message="Starting a systemd service..."
|
ynh_script_progression --message="Starting a systemd service..."
|
||||||
|
|
||||||
systemctl restart ${app}.target
|
systemctl restart ${app}.target
|
||||||
ynh_systemd_action --service_name=${app}_web.service \
|
ynh_systemd_action --service_name=${app}_web.service --action=restart --log_path="$final_path/live/log/production.log" --line_match="successfully configured the federation library"
|
||||||
--action=restart\
|
ynh_systemd_action --service_name=${app}_sidekiq.service --action=restart --log_path="systemd" --line_match="Running in ruby"
|
||||||
--log_path="$final_path/live/log/production.log" \
|
|
||||||
--line_match="successfully configured the federation library"
|
|
||||||
ynh_systemd_action --service_name=${app}_sidekiq.service \
|
|
||||||
--action=restart\
|
|
||||||
--log_path="systemd" \
|
|
||||||
--line_match="Running in ruby"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# RELOAD NGINX
|
# RELOAD NGINX
|
||||||
|
|
Loading…
Reference in a new issue