diff --git a/conf/app.src b/conf/app.src index b0020f8..d66221d 100644 --- a/conf/app.src +++ b/conf/app.src @@ -1,9 +1,9 @@ -SOURCE_URL=https://www.humhub.com/download/package/humhub-1.8.2.tar.gz -SOURCE_SUM=181d9c4519f4612949fd67e84f61ead618b200bc813fd179603c7b32f4a6e3b9 +SOURCE_URL=https://www.humhub.com/download/package/humhub-1.11.1.tar.gz +SOURCE_SUM=05f90932ae9ca933ae585844607a67efa8356f7d9cd550fcb86c8904bf7eb9de SOURCE_SUM_PRG=sha256sum SOURCE_FORMAT=tar.gz SOURCE_IN_SUBDIR=true -SOURCE_FILENAME=humhub-1.8.2.tar.gz +SOURCE_FILENAME=humhub-1.11.1.tar.gz SOURCE_EXTRACT=true diff --git a/manifest.json b/manifest.json index 3c21688..3a9a711 100644 --- a/manifest.json +++ b/manifest.json @@ -12,22 +12,21 @@ "name": "Nils Van Zuijlen", "url": "https://github.com/nils-van-zuijlen" }, - "version": "1.8.2~ynh3", + "version": "1.11.1~ynh1", "requirements": { - "yunohost": ">= 4.1.7" + "yunohost": ">= 4.3.0" }, "multi_instance": true, "services": [ "nginx", - "php7.3-fpm", + "php8.0-fpm", "mysql" ], "arguments": { "install" : [ { "name": "domain", - "type": "domain", - "example": "example.com" + "type": "domain" }, { "name": "path", @@ -37,8 +36,7 @@ }, { "name": "admin", - "type": "user", - "example": "johndoe" + "type": "user" }, { "name": "is_public", diff --git a/scripts/_common.sh b/scripts/_common.sh index 7123bfb..defdb77 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -4,7 +4,7 @@ # COMMON VARIABLES #================================================= -YNH_PHP_VERSION="7.3" +YNH_PHP_VERSION="8.0" extra_php_dependencies="php${YNH_PHP_VERSION}-imagick php${YNH_PHP_VERSION}-curl php${YNH_PHP_VERSION}-bz2 php${YNH_PHP_VERSION}-gd php${YNH_PHP_VERSION}-intl php${YNH_PHP_VERSION}-mysql php${YNH_PHP_VERSION}-zip php${YNH_PHP_VERSION}-apcu-bc php${YNH_PHP_VERSION}-apcu php${YNH_PHP_VERSION}-xml php${YNH_PHP_VERSION}-ldap" diff --git a/scripts/install b/scripts/install index a57b1fc..75bd79d 100644 --- a/scripts/install +++ b/scripts/install @@ -86,7 +86,7 @@ ynh_add_nginx_config ynh_script_progression --message="Configuring system user..." --weight=2 # Create a system user -ynh_system_user_create --username=$app +ynh_system_user_create --username=$app --home_dir="$final_path" #================================================= # PHP-FPM CONFIGURATION @@ -178,10 +178,6 @@ popd # Remove the public access ynh_permission_update --permission="main" --remove="visitors" -#================================================= -# MODIFY A CONFIG FILE -#================================================= - #================================================= # STORE THE CONFIG FILE CHECKSUM #================================================= @@ -215,8 +211,11 @@ chown -R $app $final_path/uploads/* #================================================= # SETUP CRON CONFIGURATION #================================================= +ynh_script_progression --message="Setuping a cron..." --weight=1 ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/${app}" +chown root: "/etc/cron.d/$app" +chmod 644 "/etc/cron.d/$app" #================================================= # SETUP SSOWAT diff --git a/scripts/restore b/scripts/restore index ca8c817..531095d 100644 --- a/scripts/restore +++ b/scripts/restore @@ -66,7 +66,7 @@ ynh_restore_file --origin_path="$final_path" ynh_script_progression --message="Recreating the dedicated system user..." --weight=3 # Create the dedicated user (if not existing) -ynh_system_user_create --username=$app +ynh_system_user_create --username=$app --home_dir="$final_path" #================================================= # RESTORE USER RIGHTS diff --git a/scripts/upgrade b/scripts/upgrade index f29f28d..7e5bbda 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -56,6 +56,14 @@ ynh_clean_setup () { # Exit if an error occurs during the execution of the script ynh_abort_if_errors +#================================================= +# CREATE DEDICATED USER +#================================================= +ynh_script_progression --message="Making sure dedicated system user exists..." --weight=1 + +# Create a dedicated user (if not existing) +ynh_system_user_create --username=$app --home_dir="$final_path" + #================================================= # STANDARD UPGRADE STEPS #================================================= @@ -94,14 +102,6 @@ ynh_script_progression --message="Upgrading NGINX web server configuration..." - # Create a dedicated NGINX config ynh_add_nginx_config -#================================================= -# CREATE DEDICATED USER -#================================================= -ynh_script_progression --message="Making sure dedicated system user exists..." --weight=1 - -# Create a dedicated user (if not existing) -ynh_system_user_create --username=$app - #================================================= # PHP-FPM CONFIGURATION #================================================= @@ -145,6 +145,8 @@ sudo -u $app /usr/bin/php$YNH_PHP_VERSION $final_path/protected/yii module/updat ynh_script_progression --message="Upgrading crontab..." --weight=1 ynh_add_config --template="../conf/cron" --destination="/etc/cron.d/${app}" +chown root: "/etc/cron.d/$app" +chmod 644 "/etc/cron.d/$app" #================================================= # GENERIC FINALIZATION