From 5cb34aa63ec3d840e1f9f2029ce481caca47d482 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Tue, 2 Feb 2021 14:21:41 +0100 Subject: [PATCH] Testing (#9) * Fix maintenance mail --- conf/.env.example | 8 ++++---- conf/php-fpm.conf | 4 ++-- manifest.json | 2 +- scripts/install | 2 ++ scripts/upgrade | 2 ++ 5 files changed, 11 insertions(+), 7 deletions(-) diff --git a/conf/.env.example b/conf/.env.example index 25cac05..c829544 100644 --- a/conf/.env.example +++ b/conf/.env.example @@ -38,9 +38,9 @@ MAIL_FROM=bookstack@__DOMAIN__ # These settings can be checked using the "Send a Test Email" # feature found in the "Settings > Maintenance" area of the system. MAIL_HOST=localhost -MAIL_PORT=1025 -MAIL_USERNAME=null -MAIL_PASSWORD=null +MAIL_PORT=25 +MAIL_USERNAME=bookstack +MAIL_PASSWORD="__MAIL_PWD__" MAIL_ENCRYPTION=null # General auth @@ -52,7 +52,7 @@ LDAP_SERVER=ldap://127.0.0.1:389 LDAP_BASE_DN=ou=users,dc=yunohost,dc=org LDAP_DN=false LDAP_PASS=false -LDAP_USER_FILTER=(&(|(objectclass=posixAccount))(uid={{username}})(permission=cn=__APP__.main,ou=permission,dc=yunohost,dc=org)) +LDAP_USER_FILTER="(&(|(objectclass=posixAccount))(uid={{username}})(permission=cn=__APP__.main,ou=permission,dc=yunohost,dc=org))" LDAP_VERSION=false LDAP_TLS_INSECURE=false LDAP_ID_ATTRIBUTE=uid diff --git a/conf/php-fpm.conf b/conf/php-fpm.conf index 085132b..2a4ec3d 100644 --- a/conf/php-fpm.conf +++ b/conf/php-fpm.conf @@ -419,8 +419,8 @@ chdir = __FINALPATH__ ;php_admin_value[memory_limit] = 32M ; Common values to change to increase file upload limit -php_admin_value[upload_max_filesize] = 50M -php_admin_value[post_max_size] = 50M +php_admin_value[upload_max_filesize] = 100M +php_admin_value[post_max_size] = 100M ; php_admin_flag[mail.add_x_header] = Off ; Other common parameters diff --git a/manifest.json b/manifest.json index 51d9144..4efdd38 100644 --- a/manifest.json +++ b/manifest.json @@ -6,7 +6,7 @@ "en": "Platform to create documentation/wiki content", "fr": "Plateforme pour créer du contenu de documentation/wiki " }, - "version": "0.31.4~ynh1", + "version": "0.31.4~ynh2", "url": "https://www.bookstackapp.com/", "license": "MIT", "maintainer": { diff --git a/scripts/install b/scripts/install index 4513d53..e2f6aae 100644 --- a/scripts/install +++ b/scripts/install @@ -102,6 +102,7 @@ ynh_install_composer --phpversion=$phpversion --workdir=$final_path --install_ar #================================================= # MODIFY A CONFIG FILE #================================================= + cp -a ../conf/.env.example $final_path/.env ynh_replace_string --match_string="__DB_NAME__" --replace_string="$db_name" --target_file="$final_path/.env" @@ -110,6 +111,7 @@ ynh_replace_string --match_string="__DOMAIN__" --replace_string="$domain" --targ ynh_replace_string --match_string="__PATH__" --replace_string="$path_url" --target_file="$final_path/.env" ynh_replace_string --match_string="__LANGUAGE__" --replace_string="$language" --target_file="$final_path/.env" ynh_replace_string --match_string="__APP__" --replace_string="$app" --target_file="$final_path/.env" +ynh_replace_string --match_string="__MAIL_PWD__" --replace_string="$(ynh_string_random --length=12)" --target_file="$final_path/.env" ynh_store_file_checksum $final_path/.env diff --git a/scripts/upgrade b/scripts/upgrade index 8458f9d..2b14fba 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -91,6 +91,7 @@ ynh_install_composer --phpversion=$phpversion --workdir=$final_path --install_ar #================================================= # MODIFY A CONFIG FILE #================================================= + cp -a ../conf/.env.example $final_path/.env ynh_replace_string --match_string="__DB_NAME__" --replace_string="$db_name" --target_file="$final_path/.env" @@ -99,6 +100,7 @@ ynh_replace_string --match_string="__DOMAIN__" --replace_string="$domain" --targ ynh_replace_string --match_string="__PATH__" --replace_string="$path_url" --target_file="$final_path/.env" ynh_replace_string --match_string="__LANGUAGE__" --replace_string="$language" --target_file="$final_path/.env" ynh_replace_string --match_string="__APP__" --replace_string="$app" --target_file="$final_path/.env" +ynh_replace_string --match_string="__MAIL_PWD__" --replace_string="$(ynh_string_random --length=12)" --target_file="$final_path/.env" ynh_store_file_checksum $final_path/.env