diff --git a/conf/php-fpm.conf b/conf/php-fpm.conf index cccc8e2..e6168d8 100644 --- a/conf/php-fpm.conf +++ b/conf/php-fpm.conf @@ -390,3 +390,6 @@ catch_workers_output = yes ;php_admin_value[error_log] = /var/log/fpm-php.www.log ;php_admin_flag[log_errors] = on ;php_admin_value[memory_limit] = 32M + +php_admin_value[open_basedir] = none +php_admin_value[date.timezone] = "YHTZ" \ No newline at end of file diff --git a/conf/php-fpm.ini b/conf/php-fpm.ini deleted file mode 100644 index b1221c2..0000000 --- a/conf/php-fpm.ini +++ /dev/null @@ -1,2 +0,0 @@ -open_basedir = none -date.timezone = "YHTZ" \ No newline at end of file diff --git a/manifest.json b/manifest.json index 7a8e320..d374662 100644 --- a/manifest.json +++ b/manifest.json @@ -5,20 +5,24 @@ "description": { "en": "The Kickass Social Network" }, - "version": "0.13.0~ynh1", + "version": "0.13.0~ynh2", "requirements": { - "yunohost": ">= 3.0" + "yunohost": ">= 3.4.0" }, - "url": "https://movim.eu/", + "url": "https://movim.eu", "license": "AGPL-3.0-or-later", "maintainer": { + "name": "Jean-Baptiste Holcroft", + "email": "jean-baptiste@holcroft.fr" + }, + "previous_maintainers": [{ "name": "src386", "email": "soyouz@src386.org", "url": "http://github.com/src386" - }, + }], "services": [ "nginx", - "php5-fpm", + "php-fpm", "mysql", "metronome" ], @@ -64,6 +68,7 @@ }, { "name": "language", + "type": "string", "ask": { "en": "Pod language", "fr": "Langue du pod" @@ -73,13 +78,13 @@ }, { "name": "ssoenabled", + "type": "boolean", "ask": { "en": "Enable SSO support (autologin) ?", "fr": "Activer le support SSO (connexin auto) ?" }, - "choices": ["Yes", "No"], - "default": "Yes" + "default": false } ] } -} +} \ No newline at end of file diff --git a/scripts/backup b/scripts/backup new file mode 100644 index 0000000..9674747 --- /dev/null +++ b/scripts/backup @@ -0,0 +1,18 @@ +#!/bin/bash + +#================================================= +# GENERIC START +#================================================= +# IMPORT GENERIC HELPERS +#================================================= + +source ../settings/scripts/_common.sh +source /usr/share/yunohost/helpers + +#================================================= +# MANAGE SCRIPT FAILURE +#================================================= + +# Exit if an error occurs during the execution of the script +ynh_abort_if_errors + diff --git a/scripts/install b/scripts/install index 5dc2a07..278c35b 100644 --- a/scripts/install +++ b/scripts/install @@ -123,7 +123,7 @@ ynh_system_user_create "$app" #================================================= # Create a dedicated php-fpm config -ynh_replace_string "YHTZ" "$timezone" ../conf/php-fpm.ini +ynh_replace_string "YHTZ" "$timezone" ../conf/php-fpm.conf ynh_add_fpm_config #================================================= @@ -190,7 +190,7 @@ chmod 400 "${final_path}/config/db.inc.php" #================================================= # SSOwat configuration -if [[ "$ssoenabled" = "No" ]]; then +if [[ "$ssoenabled" -eq 0 ]]; then ynh_app_setting_set "$app" skipped_uris "/" (cd "$final_path" && php mud.php config --xmppwhitelist="$domain") undo_sso_patch diff --git a/scripts/restore b/scripts/restore new file mode 100644 index 0000000..9674747 --- /dev/null +++ b/scripts/restore @@ -0,0 +1,18 @@ +#!/bin/bash + +#================================================= +# GENERIC START +#================================================= +# IMPORT GENERIC HELPERS +#================================================= + +source ../settings/scripts/_common.sh +source /usr/share/yunohost/helpers + +#================================================= +# MANAGE SCRIPT FAILURE +#================================================= + +# Exit if an error occurs during the execution of the script +ynh_abort_if_errors + diff --git a/scripts/upgrade b/scripts/upgrade index 939f1f0..fb67c1e 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -42,6 +42,16 @@ if [ -z "$db_name" ]; then ynh_app_setting_set "$app" db_name "$db_name" fi + +# Fix ssoenabled as a boolean value +if [ "$ssoenabled" = "Yes" ]; then + ynh_app_setting_set $app ssoenabled 1 + ssoenabled=1 +elif [ "$ssoenabled" = "No" ]; then + ynh_app_setting_set $app ssoenabled 0 + ssoenabled=0 +fi + #================================================= # ACTIVE TRAP #=================================================