The libexec script doesn't honor the SAVE_OPTIONS variable. This commit fixes
that issue.
Thanks to Phil@nwl.cc for providing the fix for the issue.
Gentoo-bug: 603228
Package-Manager: Portage-2.3.3, Repoman-2.3.1
"store")
local tmp_save="${NFTABLES_SAVE}.tmp"
if ! use_legacy; then
- nft list ruleset > ${tmp_save}
+ nft ${SAVE_OPTIONS} list ruleset > ${tmp_save}
else
save_legacy ${tmp_save}
fi
#!/sbin/openrc-run
-# Copyright 2014-2016 Nicholas Vinson
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 2014-2017 Nicholas Vinson
+# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
extra_commands="clear list panic save"
ebegin "Saving nftables state"
checkpath -q -d "$(dirname "${NFTABLES_SAVE}")"
checkpath -q -m 0600 -f "${NFTABLES_SAVE}"
+ export SAVE_OPTIONS
/usr/libexec/nftables/nftables.sh store ${NFTABLES_SAVE}
return $?
}