[packages/rpm-build-tools/netns-with-lo-addr] builder: fix ip commands chaining

atler atler at pld-linux.org
Mon Oct 27 02:16:52 CET 2025


commit 52eaa12d930672ba27bfd3f202a6987e88a40c45
Author: Jan Palus <atler at pld-linux.org>
Date:   Mon Oct 27 02:16:03 2025 +0100

    builder: fix ip commands chaining

 builder.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/builder.sh b/builder.sh
index 6fbc894..b79c7cf 100755
--- a/builder.sh
+++ b/builder.sh
@@ -153,7 +153,7 @@ REVERT_BROKEN_UPGRADE="yes"
 IP=/sbin/ip
 
 # disable network for rpm build tool, autodetect if it works (doesn't work in chroot and in vserver guest)
-unshare --user --net --map-current-user true 2> /dev/null && NONETWORK="unshare --user --net --map-root-user $SHELL -c 'test -x $IP && $IP a add 127.0.0.1/8 dev lo && $IP a add ::1/128 dev lo noprefixroute; $IP l set lo up; exec unshare --map-user $(id -un) $SHELL'" || NONETWORK=""
+unshare --user --net --map-current-user true 2> /dev/null && NONETWORK="unshare --user --net --map-root-user $SHELL -c 'test -x $IP && $IP a add 127.0.0.1/8 dev lo && $IP a add ::1/128 dev lo noprefixroute && $IP l set lo up; exec unshare --map-user $(id -un) $SHELL'" || NONETWORK=""
 
 if rpm --specsrpm 2>/dev/null; then
 	FETCH_BUILD_REQUIRES_RPMSPECSRPM="yes"
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/rpm-build-tools.git/commitdiff/52eaa12d930672ba27bfd3f202a6987e88a40c45



More information about the pld-cvs-commit mailing list