From 44f02cd25400407773a9074ec5cdcfb64dfc18c8 Mon Sep 17 00:00:00 2001 From: Adam Miller Date: May 16 2016 18:02:05 +0000 Subject: - fix whitespace issues with tab characters vs spaces - fix invalid variable names in livemediacreator handler - add parser for ostree pxe2live to cli --- diff --git a/builder/kojid b/builder/kojid index b122d16..84123b6 100755 --- a/builder/kojid +++ b/builder/kojid @@ -2876,16 +2876,16 @@ class LiveMediaTask(ImageTask): ] # Determine what LMC opperation we are doing: live-iso, live-pxe, disk-img. - if live-iso: + if live_iso: # we set the fs label to the same as the isoname if it exists, # taking at most 32 characters isoname = '%s-%s-%s' % (name, version, release) cmd.extend(['--make-iso', '--volid', isoname[:32]]) - elif live-ostree-pxe: + elif live_ostree_pxe: cmd.extend(['--make-ostree-live']) - elif disk-img: + elif disk_img: img_name='disk.img' prj_name='Fedora' cmd.extend(['--make-disk', @@ -2894,10 +2894,10 @@ class LiveMediaTask(ImageTask): '--releasever', release ]) - else - # bail - raise koji.LiveMediaError, \ - 'This task needs an option: --live-iso or --live-ostree-pxe or --disk-img' + else: + # bail + raise koji.LiveMediaError, \ + 'This task needs an option: --live-iso or --live-ostree-pxe or --disk-img' # Run livemedia-creator rv = broot.mock(['--cwd', '/tmp', '--chroot', '--'] + cmd) diff --git a/cli/koji b/cli/koji index 1d9461b..8154731 100755 --- a/cli/koji +++ b/cli/koji @@ -5252,6 +5252,8 @@ def handle_spin_livemedia(options, session, args): help=_("SCM URL to spec file fragment to use to generate wrapper RPMs")) parser.add_option("--skip-tag", action="store_true", help=_("Do not attempt to tag package")) + parser.add_option("--live-ostree-pxe", action="store_true", + help=_("Build a live pxe boot squashfs image of Atomic Host")) (task_options, args) = parser.parse_args(args) # LMC operations @@ -5636,7 +5638,8 @@ def _build_image(options, task_opts, session, args, img_type): hub_opts = {} for opt in ('isoname', 'ksurl', 'ksversion', 'scratch', 'repo', - 'release', 'skip_tag', 'vmem', 'vcpu', 'format', 'specfile'): + 'release', 'skip_tag', 'vmem', 'vcpu', 'format', 'specfile', + 'live_ostree_pxe'): val = getattr(task_opts, opt, None) if val is not None: hub_opts[opt] = val