From 4ce465d31a40af1909402cce2ef7dc3628443223 Mon Sep 17 00:00:00 2001 From: Chris Vogel Date: Sat, 27 Apr 2024 14:04:21 +0200 Subject: [PATCH] replaced " by ' because content itself contained " --- scripts/install | 5 ++--- scripts/upgrade | 5 ++--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/scripts/install b/scripts/install index 94505c1..7e79ec3 100755 --- a/scripts/install +++ b/scripts/install @@ -122,8 +122,7 @@ chmod 640 "/var/log/$app/$app.log" ynh_systemd_action --service_name=$app --action="start" # SETUP FAIL2BAN -# @@ todo -# ynh_script_progression --message="Configuring Fail2Ban..." --weight=3 -# ynh_add_fail2ban_config --logpath="/var/log/$app/$app.log" --failregex=":" --max_retry=5 +ynh_script_progression --message="Configuring Fail2Ban..." --weight=3 +ynh_add_fail2ban_config --logpath="/var/log/$app/$app.log" --failregex='INFO: +:\d+ - "POST /token HTTP/\d+\.\d+" 403 Forbidden' --max_retry=5 ynh_script_progression --message="Installation of $app completed" --last diff --git a/scripts/upgrade b/scripts/upgrade index 33362ef..e36f6c7 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -93,9 +93,8 @@ ynh_script_progression --message="Upgrading NGINX web server configuration..." - ynh_add_nginx_config # UPGRADE FAIL2BAN -# ynh_script_progression --message="Reconfiguring Fail2Ban..." --weight=3 -# Create a dedicated Fail2Ban config -# ynh_add_fail2ban_config --logpath="/var/log/couchdb/couchdb.log" --failregex="[warning] .*couch_httpd_auth: Authentication failed for user .+ from " --max_retry=5 +ynh_script_progression --message="Reconfiguring Fail2Ban..." --weight=3 +ynh_add_fail2ban_config --logpath="/var/log/$app/$app.log" --failregex='INFO: +:\d+ - "POST /token HTTP/\d+\.\d+" 403 Forbidden' --max_retry=5 # start flohmarkt ynh_script_progression --message="Starting flohmarkt..." --weight=3