From efb0cce9b85a157cbf526bc22a7bcc37a87b6500 Mon Sep 17 00:00:00 2001 From: "Brian C. Lane" Date: Thu, 21 Apr 2016 10:38:29 -0700 Subject: [PATCH] Change --make-pxe-live --no-virt use a fsimage Instead of a partitioned disk image. This will allow a single pass of lmc to be used to create an ostree live PXE image. --- src/sbin/livemedia-creator | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/sbin/livemedia-creator b/src/sbin/livemedia-creator index 3cca322e..ed908ac5 100755 --- a/src/sbin/livemedia-creator +++ b/src/sbin/livemedia-creator @@ -717,7 +717,7 @@ def novirt_install(opts, disk_img, disk_size): if opts.armplatform: args += ["--armplatform", opts.armplatform] - if opts.make_iso or opts.make_fsimage: + if opts.make_iso or opts.make_fsimage or opts.make_pxe_live: # Make a blank fs image args += ["--dirinstall"] @@ -783,7 +783,7 @@ def novirt_install(opts, disk_img, disk_size): shutil.copy2(l, log_anaconda) os.unlink(l) - if not opts.make_iso and not opts.make_fsimage: + if not opts.make_iso and not opts.make_fsimage and not opts.make_pxe_live: dm_name = os.path.splitext(os.path.basename(disk_img))[0] dm_path = "/dev/mapper/"+dm_name if os.path.exists(dm_path): @@ -1389,7 +1389,7 @@ def main(): work_dir = tempfile.mkdtemp(prefix="lmc-work-") log.info("working dir is %s", work_dir) - if opts.fs_image and not opts.disk_image: + if opts.fs_image or opts.no_virt: # Create pxe live images from a filesystem image disk_img = opts.fs_image or disk_img with Mount(disk_img, opts="loop") as mnt_dir: