mirror of
https://github.com/RichieCahill/dotfiles.git
synced 2026-04-17 04:58:19 -04:00
moved common out of systems
This commit is contained in:
14
common/global/fail2ban.nix
Normal file
14
common/global/fail2ban.nix
Normal file
@@ -0,0 +1,14 @@
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
services.fail2ban = {
|
||||
enable = lib.mkIf config.networking.firewall.enable (lib.mkDefault true);
|
||||
maxretry = 5;
|
||||
bantime = "24h";
|
||||
bantime-increment = {
|
||||
enable = true;
|
||||
formula = "ban.Time * math.exp(float(ban.Count+1)*banFactor)/math.exp(1*banFactor)";
|
||||
maxtime = "168h";
|
||||
overalljails = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user