mirror of
https://github.com/moby/moby.git
synced 2026-01-11 10:41:43 +00:00
contrib/rootless-setuptool: Fix iptables detection
Fix a logical error in the rootless setup tool where the iptables error handling was incorrectly placed. The code was setting `faced_iptables_error=1` even when iptables was available, causing unnecessary error messages and setup suggestions. This patch correctly moves the error handling into the `else` branch so that we only report iptables errors when the command is actually unavailable. Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
This commit is contained in:
@@ -152,6 +152,7 @@ init() {
|
||||
case $iptables_version in
|
||||
*legacy*) iptables_module="ip_tables" ;;
|
||||
esac
|
||||
else
|
||||
faced_iptables_error=1
|
||||
if [ -z "$OPT_SKIP_IPTABLES" ]; then
|
||||
if command -v apt-get > /dev/null 2>&1; then
|
||||
|
||||
Reference in New Issue
Block a user