mirror of
https://github.com/YunoHost-Apps/piwigo_ynh.git
synced 2024-09-03 20:06:03 +02:00
Fix
This commit is contained in:
parent
c80c54e973
commit
bc33bc83f4
7 changed files with 13 additions and 15 deletions
|
@ -6,7 +6,7 @@
|
||||||
"en": "Open source photo gallery for the web",
|
"en": "Open source photo gallery for the web",
|
||||||
"fr": "Galerie de photos open source pour le web"
|
"fr": "Galerie de photos open source pour le web"
|
||||||
},
|
},
|
||||||
"version": "2.10.2~ynh1",
|
"version": "2.10.2~ynh2",
|
||||||
"url": "http://piwigo.org",
|
"url": "http://piwigo.org",
|
||||||
"license": "GPL-2.0",
|
"license": "GPL-2.0",
|
||||||
"maintainer": {
|
"maintainer": {
|
||||||
|
|
|
@ -6,9 +6,7 @@
|
||||||
|
|
||||||
YNH_PHP_VERSION="7.3"
|
YNH_PHP_VERSION="7.3"
|
||||||
|
|
||||||
pkg_dependencies="imagemagick"
|
pkg_dependencies="php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-imagick imagemagick"
|
||||||
|
|
||||||
extra_php_dependencies="php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-imagick"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# EXPERIMENTAL HELPERS
|
# EXPERIMENTAL HELPERS
|
||||||
|
|
|
@ -75,4 +75,4 @@ ynh_backup --src_path="/home/yunohost.app/${app}/upload" --is_big
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_print_info --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)."
|
ynh_print_info --message="Backup script completed for Piwigo. (YunoHost will then actually copy those files to the archive)."
|
||||||
|
|
|
@ -54,19 +54,19 @@ ynh_script_progression --message="Updating NGINX web server configuration..." --
|
||||||
|
|
||||||
nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf
|
nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf
|
||||||
|
|
||||||
# Change the path in the nginx config file
|
# Change the path in the NGINX config file
|
||||||
if [ $change_path -eq 1 ]
|
if [ $change_path -eq 1 ]
|
||||||
then
|
then
|
||||||
# Make a backup of the original nginx config file if modified
|
# Make a backup of the original NGINX config file if modified
|
||||||
ynh_backup_if_checksum_is_different --file="$nginx_conf_path"
|
ynh_backup_if_checksum_is_different --file="$nginx_conf_path"
|
||||||
# Set global variables for nginx helper
|
# Set global variables for nginx helper
|
||||||
domain="$old_domain"
|
domain="$old_domain"
|
||||||
path_url="$new_path"
|
path_url="$new_path"
|
||||||
# Create a dedicated nginx config
|
# Create a dedicated NGINX config
|
||||||
ynh_add_nginx_config
|
ynh_add_nginx_config
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Change the domain for nginx
|
# Change the domain for NGINX
|
||||||
if [ $change_domain -eq 1 ]
|
if [ $change_domain -eq 1 ]
|
||||||
then
|
then
|
||||||
# Delete file checksum for the old conf file location
|
# Delete file checksum for the old conf file location
|
||||||
|
@ -89,4 +89,4 @@ ynh_systemd_action --service_name=nginx --action=reload
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_script_progression --message="Change of URL completed for $app" --last
|
ynh_script_progression --message="Change of URL completed for Piwigo" --last
|
||||||
|
|
|
@ -138,8 +138,8 @@ ynh_secure_remove --file="$tmpdir"
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Configuring PHP-FPM..." --weight=2
|
ynh_script_progression --message="Configuring PHP-FPM..." --weight=2
|
||||||
|
|
||||||
# Create a dedicated php-fpm config
|
# Create a dedicated PHP-FPM config
|
||||||
ynh_add_fpm_config --phpversion=$YNH_PHP_VERSION --package="$extra_php_dependencies"
|
ynh_add_fpm_config --phpversion=$YNH_PHP_VERSION
|
||||||
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
|
phpversion=$(ynh_app_setting_get --app=$app --key=phpversion)
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
|
@ -100,7 +100,7 @@ ynh_systemd_action --action=restart --service_name=fail2ban
|
||||||
ynh_script_progression --message="Reinstalling dependencies..." --weight=40
|
ynh_script_progression --message="Reinstalling dependencies..." --weight=40
|
||||||
|
|
||||||
# Define and install dependencies
|
# Define and install dependencies
|
||||||
ynh_install_app_dependencies $pkg_dependencies
|
ynh_install_app_dependencies "$pkg_dependencies"
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# RESTORE THE DATA DIRECTORY
|
# RESTORE THE DATA DIRECTORY
|
||||||
|
@ -111,7 +111,7 @@ ynh_script_progression --message="Restoring data directory..."
|
||||||
ynh_restore_file --origin_path="/home/yunohost.app/$app/upload" --not_mandatory
|
ynh_restore_file --origin_path="/home/yunohost.app/$app/upload" --not_mandatory
|
||||||
|
|
||||||
# Create app folders
|
# Create app folders
|
||||||
mkdir -p "/home/yunohost.app/$app/upload"
|
mkdir -p /home/yunohost.app/$app/upload
|
||||||
|
|
||||||
# Create temporary data folder
|
# Create temporary data folder
|
||||||
mkdir -p /home/yunohost.app/$app/_data
|
mkdir -p /home/yunohost.app/$app/_data
|
||||||
|
|
|
@ -305,4 +305,4 @@ ynh_systemd_action --service_name=nginx --action=reload
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
||||||
ynh_script_progression --message="Upgrade of Pixigo completed" --last
|
ynh_script_progression --message="Upgrade of Piwigo completed" --last
|
||||||
|
|
Loading…
Reference in a new issue