[1]
/etc/nginx/blockips.conf:
/etc/nginx/blockips.conf
deny 1.2.3.4; deny 5.6.7.8; # deny 192.168.1.0/24; # deny all;
在 /etc/nginx/nginx.conf 中 http 块中加入
/etc/nginx/nginx.conf
http
include blockips.conf;