Skip to content

Instantly share code, notes, and snippets.

@lovesegfault
Created December 15, 2019 03:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lovesegfault/74d0babbc9a037111fd411d98dfe74aa to your computer and use it in GitHub Desktop.
Save lovesegfault/74d0babbc9a037111fd411d98dfe74aa to your computer and use it in GitHub Desktop.
{config, lib, ...}: {
helpers =
''
# Helper command to manipulate both the IPv4 and IPv6 tables.
ip46tables() {
iptables -w "$@"
${lib.optionalString config.networking.enableIPv6 ''
ip6tables -w "$@"
''}
}
'';
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment