bunkerweb/scripts/abusers.sh
2020-10-21 23:28:48 +02:00

11 lines
287 B
Bash
Executable File

#!/bin/sh
echo "" > /etc/nginx/block-abusers.conf
curl -s "https://iplists.firehol.org/files/firehol_abusers_30d.netset" | grep -v "^\#.*" |
while read entry ; do
echo "deny ${entry};" >> /etc/nginx/block-abusers.conf
done
if [ -f /tmp/nginx.pid ] ; then
/usr/sbin/nginx -s reload
fi