diff options
author | Hilton Chain <hako@ultrarare.space> | 2023-09-12 13:47:02 +0800 |
---|---|---|
committer | Hilton Chain <hako@ultrarare.space> | 2023-12-19 21:48:17 +0800 |
commit | 6884770464bd9ba95c1a5ccf10bf50d186a220d5 (patch) | |
tree | f9b14735a475879c32575eeaa4fe1dadcf937838 /gnu | |
parent | 521247658fbfc39efc4e86212c1559acebae3395 (diff) | |
download | guix-6884770464bd9ba95c1a5ccf10bf50d186a220d5.tar.gz |
gnu: Add iptables-nft.
* gnu/packages/linux.scm (iptables-nft): New variable. Change-Id: I281514fcf05e70b4d62f374269c50c76bb676f78
Diffstat (limited to 'gnu')
-rw-r--r-- | gnu/packages/linux.scm | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index c4da631089..2df711aab2 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -3101,6 +3101,40 @@ Both commands are targeted at system administrators.") '((release-monitoring-url . "https://www.netfilter.org/pub/iptables/"))) (license license:gpl2+))) +(define-public iptables-nft + (package + (inherit iptables) + (name "iptables-nft") + (source #f) + (build-system copy-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (delete 'unpack) + (replace 'install + (lambda* (#:key inputs #:allow-other-keys) + (for-each + (lambda (command-path) + (let ((link-path (string-append #$output command-path))) + (mkdir-p (dirname link-path)) + (symlink (search-input-file inputs "sbin/xtables-nft-multi") + link-path))) + (apply append + '("/bin/iptables-xml") + (map (lambda (xtables) + (list (string-append "/sbin/" xtables) + (string-append "/sbin/" xtables "-restore") + (string-append "/sbin/" xtables "-save"))) + '("arptables" + "ebtables" + "iptables" + "ip6tables"))))))))) + (inputs (list iptables)) + (native-inputs '()) + (synopsis + "Programs to configure Linux IP packet filtering rules (nftables API)"))) + (define-public bolt (package (name "bolt") |