From ee2c6ed8e9a41634bdce42f54eced76fcd9ce497 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?E=CC=81ric=20Gaspar?= <46165813+ericgaspar@users.noreply.github.com> Date: Wed, 14 Jun 2023 14:15:36 +0200 Subject: [PATCH] fix --- manifest.toml | 9 ++++++++- scripts/install | 8 +++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/manifest.toml b/manifest.toml index 5322121..478dda9 100644 --- a/manifest.toml +++ b/manifest.toml @@ -18,7 +18,7 @@ userdoc = "https://www.bookstackapp.com/docs/user/" code = "https://github.com/BookStackApp/BookStack" [integration] -yunohost = ">= 11.1.19" +yunohost = ">= 11.1.20" architectures = "all" multi_instance = true ldap = true @@ -58,6 +58,13 @@ ram.runtime = "50M" type = "group" default = "visitors" + [install.password] + # this is a generic question - ask strings are automatically handled by YunoHost's core + # Note that user-provided passwords questions are not automatically saved as setting + help.en = "The password is needed only if you select standard authentication." + help.fr = "Le mot de passe n'est requis que si vous sélectionnez l'authentification standard." + type = "password" + [resources] [resources.sources] diff --git a/scripts/install b/scripts/install index 40bff2c..28c47fb 100644 --- a/scripts/install +++ b/scripts/install @@ -85,7 +85,13 @@ ynh_script_progression --message="Install BookStack" --weight=5 pushd $install_dir php$phpversion artisan key:generate --no-interaction --force php$phpversion artisan migrate --no-interaction --force - php$phpversion artisan bookstack:create-admin --email="$email" --name="$admin" --external-auth-id="$admin" + if [ "$auth_method" = "ldap" ] + then + php$phpversion artisan bookstack:create-admin --email="$email" --name="$admin" --external-auth-id="$admin" + else + php$phpversion artisan bookstack:create-admin --email="$email" --name="$admin" --password="$password" + fi + popd #=================================================