diff --git a/scripts/install b/scripts/install index 8acd52f..e94a4a1 100755 --- a/scripts/install +++ b/scripts/install @@ -123,19 +123,9 @@ ynh_install_java --java_version=$java_version --jdk_type=jre ynh_install_app_dependencies $pkg_dependencies -ynh_print_info --message="Debian release is $(ynh_get_debian_release)" - # Install the required version of Mongo ynh_install_mongo --mongo_version=$mongo_version -# Try to get better error message from Mongo about why it doesn't start -ynh_exec_warn journalctl --quiet --no-hostname --no-pager --lines=100 --unit=mongod -log_path="/var/log/mongodb/mongod.log" -if [ -e "$log_path" ]; then - ynh_print_warn --message="\-\-\-" - ynh_exec_warn tail --lines=100 "$log_path" -fi - #================================================= # CREATE DEDICATED USER #================================================= diff --git a/scripts/ynh_mongo_db__2 b/scripts/ynh_mongo_db__2 index 7fac585..04d1dcb 100644 --- a/scripts/ynh_mongo_db__2 +++ b/scripts/ynh_mongo_db__2 @@ -1,7 +1,7 @@ #!/bin/bash readonly YNH_DEFAULT_MONGO_VERSION=4.4 -# Declare the actual MongoDB version to use: 4.4 ; 5.0 +# Declare the actual MongoDB version to use: 4.4 ; 5.0 ; 6.0 # A packager willing to use another version of MongoDB can override the variable into its _common.sh. YNH_MONGO_VERSION=${YNH_MONGO_VERSION:-$YNH_DEFAULT_MONGO_VERSION} @@ -319,7 +319,7 @@ ynh_install_mongo() { # Make sure MongoDB is started and enabled systemctl enable $mongodb_servicename --quiet systemctl daemon-reload --quiet - ynh_systemd_action --service_name=$mongodb_servicename --action=restart --line_match="aiting for connections" --log_path="/var/log/mongodb/$mongodb_servicename.log" + ynh_systemd_action --service_name=$mongodb_servicename --action=restart --line_match="aiting for connections" --log_path="/var/log/mongodb/$mongodb_servicename.log" --length=100 # Integrate MongoDB service in YunoHost yunohost service add $mongodb_servicename --description="MongoDB daemon" --log="/var/log/mongodb/$mongodb_servicename.log"