Skip to content

Commit

Permalink
Minor fixes for custom boot params
Browse files Browse the repository at this point in the history
Modified to rstrip instead of strip as we need
to keep leading `,` and we need kernel params
to be given in quotes as virt-install cmdline
complains.

Signed-off-by: Satheesh Rajendran <sathnaga@linux.vnet.ibm.com>
  • Loading branch information
Satheesh Rajendran committed May 23, 2018
1 parent d661db2 commit 8aaceb1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions virttest/libvirt_vm.py
Original file line number Diff line number Diff line change
Expand Up @@ -876,11 +876,11 @@ def add_kernel(help_text, cmdline, kernel_path=None, initrd_path=None,
if has_sub_option("boot", "initrd") and initrd_path:
result += "initrd=%s," % initrd_path
if has_sub_option("boot", "kernel_args") and kernel_args:
result += "kernel_args=%s," % kernel_args
result += "kernel_args=\"%s\"," % kernel_args
else:
result = ""
logging.warning("boot option is not supported")
return result.strip(',')
return result.rstrip(',')

# End of command line option wrappers

Expand Down

0 comments on commit 8aaceb1

Please sign in to comment.