Add support for setting the volume ID of the output image
If we don't set it, xorriso will just call things "ISOIMAGE"
This commit is contained in:
parent
5b23a4cf06
commit
2736511983
2 changed files with 10 additions and 2 deletions
|
|
@ -74,6 +74,11 @@ class LiveWrapper(cliapp.Application):
|
|||
metavar='DESCRIPTION',
|
||||
group='Base Settings',
|
||||
default=None)
|
||||
self.settings.string(
|
||||
['volume_id'], 'Volume ID for the image (default: %default)',
|
||||
metavar='VOLID',
|
||||
group='Base Settings',
|
||||
default='DEBIAN LIVE')
|
||||
self.settings.string(
|
||||
['t', 'tasks'], 'Task packages to install',
|
||||
metavar='"task-TASK1 task-TASK2 ..."',
|
||||
|
|
@ -319,6 +324,7 @@ class LiveWrapper(cliapp.Application):
|
|||
# Create ISO image
|
||||
logging.info("Creating the ISO image with Xorriso...")
|
||||
xorriso = Xorriso(self.settings['image_output'],
|
||||
self.settings['volume_id'],
|
||||
isolinux=self.settings['isolinux'],
|
||||
grub=self.settings['grub'])
|
||||
xorriso.build_args(self.cdroot.path)
|
||||
|
|
|
|||
|
|
@ -24,8 +24,9 @@ class Xorriso(object):
|
|||
application.
|
||||
"""
|
||||
|
||||
def __init__(self, image_output, isolinux=True, grub=True):
|
||||
def __init__(self, image_output, volume_id, isolinux=True, grub=True):
|
||||
self.image_output = image_output
|
||||
self.volume_id = volume_id
|
||||
self.isolinux = isolinux
|
||||
self.grub = grub
|
||||
self.args = ['xorriso']
|
||||
|
|
@ -35,7 +36,8 @@ class Xorriso(object):
|
|||
cliapp.AppException("Attempted to rebuild xorriso arguments while"
|
||||
"they are already defined!")
|
||||
self.args.extend(['-outdev', self.image_output])
|
||||
self.args.extend(['map', cdroot, '/'])
|
||||
self.args.extend(['-volid', self.volume_id])
|
||||
self.args.extend(['-map', cdroot, '/'])
|
||||
|
||||
if self.isolinux:
|
||||
self.args.extend(['-boot_image', 'isolinux', 'dir=/isolinux',
|
||||
|
|
|
|||
Loading…
Reference in a new issue