Add p14 configuration

This commit is contained in:
Sonny Bakker 2026-02-24 19:46:53 +01:00
parent be2ed3c9bf
commit 5fe1764dbe
32 changed files with 332 additions and 14 deletions

43
templates/p14/nftables.j2 Normal file
View file

@ -0,0 +1,43 @@
#!/usr/bin/nft -f
# vim:set ts=2 sw=2 et:
flush ruleset
table inet filter {
chain input {
type filter hook input priority 0; policy drop;
# allow established/related connections
ct state { established, related } accept
# early drop of invalid connections
ct state invalid drop
# allow from loopback
iifname lo accept
# allow icmp
ip protocol icmp accept
ip6 nexthdr icmpv6 accept
# allow mDNS
udp dport 5353 accept
# allow ssh
tcp dport ssh accept
}
chain forward {
type filter hook forward priority security; policy drop;
ct state { established, related } accept;
mark 1 accept
}
}
table ip filter {
chain DOCKER-USER {
mark set 1
}
}