nixos-config/machines/shinobu/services/router/common.nix

66 lines
1.1 KiB
Nix
Raw Normal View History

2023-09-24 14:41:22 +02:00
{
domain = "home.sbruder.de";
tc = {
interface = "enp1s0";
# 4160kbit is slightly smaller than the average upload
rate = "4160kbit";
major = 1;
default = 2;
classes = [
# default
{
minor = 2;
rate = "1000kbit";
prio = 50;
}
# DNS, small packets (e.g., TCP ACK)
{
minor = 3;
rate = "250kbit";
prio = 0;
qdiscArgs = [ "pfifo_fast" ];
}
# interactive SSH
{
minor = 4;
rate = "128kbit";
prio = 2;
}
# torrent
{
minor = 5;
rate = "250kbit";
ceil = "3000kbit";
prio = 100;
}
# HTTP
{
minor = 6;
rate = "1500kbit";
prio = 25;
}
# wg-home
{
minor = 7;
rate = "250kbit";
prio = 10;
}
# VoIP
{
minor = 8;
rate = "256kbit";
ceil = "384kbit";
prio = 3;
qdiscArgs = [ "pfifo_fast" ];
}
# Backup
{
minor = 9;
rate = "350kbit";
ceil = "3000kbit";
prio = 90;
}
];
};
2023-09-24 14:41:22 +02:00
}