From a8681aca4eb932aa1391e054a14cb0c73206afc8 Mon Sep 17 00:00:00 2001 From: "Brian C. Lane" Date: Wed, 27 Aug 2014 16:49:47 -0700 Subject: [PATCH] livemedia-creator: Add --no-recursion to mktar (#1144140) tar recurses into directories by default, but find is feeding it all the files and directories so the tar it produces is considerably larger than it needs to be due to duplicate files. Add --no-recursion flag so that tar will only add the specific files and directories piped to it by find. Related: rhbz#1144140 --- src/pylorax/imgutils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pylorax/imgutils.py b/src/pylorax/imgutils.py index e202c65f..91fd73c2 100644 --- a/src/pylorax/imgutils.py +++ b/src/pylorax/imgutils.py @@ -78,7 +78,8 @@ def mkcpio(rootdir, outfile, compression="xz", compressargs=["-9"]): rootdir, outfile, compression, compressargs) def mktar(rootdir, outfile, compression="xz", compressargs=["-9"]): - return compress(["tar", "--selinux", "--acls", "--xattrs", "-cf-", "--null", "-T-"], + compressargs = compressargs or ["-9"] + return compress(["tar", "--no-recursion", "--selinux", "--acls", "--xattrs", "-cf-", "--null", "-T-"], rootdir, outfile, compression, compressargs) def mksquashfs(rootdir, outfile, compression="default", compressargs=[]):