diff --git a/scripts/install b/scripts/install index 67fecea..1e0f18e 100644 --- a/scripts/install +++ b/scripts/install @@ -131,9 +131,7 @@ ynh_replace_string --match_string="# engine:" --replace_string=" engine: wired ynh_replace_string --match_string="#replication:" --replace_string="replication:\n replSetName: rs01" --target_file=$MONGO_CE_CONFIG ynh_exec_warn_less systemctl enable $MONGO_CE_SERVICENAME --quiet -ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart - -sleep 10 +ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart --log_path=/var/log/mongodb/$MONGO_CE_SERVICENAME.log --line_match="Waiting for connections" if ynh_exec_warn_less ynh_mongo_exec --command="printjson(rs.status())" | grep -q "no replset config has been received"; then ynh_exec_warn_less ynh_mongo_exec --command="printjson(rs.initiate())" --eval diff --git a/scripts/remove b/scripts/remove index 1e1c42b..38d4ad6 100644 --- a/scripts/remove +++ b/scripts/remove @@ -60,9 +60,7 @@ ynh_replace_string --match_string="engine: wiredTiger" --replace_string="# engi ynh_replace_string --match_string="replication:" --replace_string="#replication:" --target_file=$MONGO_CE_CONFIG ynh_replace_string --match_string=" replSetName: rs01" --replace_string="" --target_file=$MONGO_CE_CONFIG -ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart - -sleep 10 +ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart --log_path=/var/log/mongodb/$MONGO_CE_SERVICENAME.log --line_match="Waiting for connections" # Remove a database if it exists, along with the associated user ynh_mongo_remove_db --db_user=$db_user --db_name=$db_name diff --git a/scripts/restore b/scripts/restore index 514d35e..dceea60 100644 --- a/scripts/restore +++ b/scripts/restore @@ -99,9 +99,7 @@ ynh_replace_string --match_string="# engine:" --replace_string=" engine: wired ynh_replace_string --match_string="#replication:" --replace_string="replication:\n replSetName: rs01" --target_file=$MONGO_CE_CONFIG ynh_exec_warn_less systemctl enable $MONGO_CE_SERVICENAME --quiet -ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart - -sleep 10 +ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart --log_path=/var/log/mongodb/$MONGO_CE_SERVICENAME.log --line_match="Waiting for connections" if ynh_exec_warn_less ynh_mongo_exec --command="printjson(rs.status())" | grep -q "no replset config has been received"; then ynh_exec_warn_less ynh_mongo_exec --command="printjson(rs.initiate())" --eval diff --git a/scripts/upgrade b/scripts/upgrade index 744877b..9025833 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -128,9 +128,7 @@ ynh_replace_string --match_string="# engine:" --replace_string=" engine: wired ynh_replace_string --match_string="#replication:" --replace_string="replication:\n replSetName: rs01" --target_file=$MONGO_CE_CONFIG ynh_exec_warn_less systemctl enable $MONGO_CE_SERVICENAME --quiet -ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart - -sleep 10 +ynh_systemd_action --service_name=$MONGO_CE_SERVICENAME --action=restart --log_path=/var/log/mongodb/$MONGO_CE_SERVICENAME.log --line_match="Waiting for connections" if ynh_exec_warn_less ynh_mongo_exec --command="printjson(rs.status())" | grep -q "no replset config has been received"; then ynh_exec_warn_less ynh_mongo_exec --command="printjson(rs.initiate())" --eval