1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/z-push_ynh.git synced 2024-09-03 18:05:58 +02:00

include the fail2ban feature not included before

Need to relaunch fail2ban, but adding this will work. Checked more than twice...
This commit is contained in:
bjarkan 2020-08-26 23:04:11 +02:00 committed by GitHub
parent e94afa2fe7
commit 054be0dc03
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -217,6 +217,13 @@ ynh_print_info --message="Securing files and directories..."
# Set permissions to app files # Set permissions to app files
chown -R $app: $final_path chown -R $app: $final_path
##add jail2ban file
echo "[z-push] " > /etc/fail2ban/jail.d/z-push.conf
echo "enable = true" >> /etc/fail2ban/jail.d/z-push.conf
echo "port = http, https" >> /etc/fail2ban/jail.d/z-push.conf
echo "filter = z-push " >> /etc/fail2ban/jail.d/z-push.conf
echo "logpath = /var/log/z-push/z-push-error.log" >> /etc/fail2ban/jail.d/z-push.conf
## that easy
#================================================= #=================================================
# SETUP LOGROTATE # SETUP LOGROTATE