[createiso] Add customizing disc type
Relates: #105 Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
parent
44d7b31a80
commit
72f9819779
@ -245,6 +245,7 @@ There a couple common format specifiers available for both the options:
|
|||||||
Available keys are:
|
Available keys are:
|
||||||
* ``boot`` -- for ``boot.iso`` images created in *buildinstall* phase
|
* ``boot`` -- for ``boot.iso`` images created in *buildinstall* phase
|
||||||
* ``live`` -- for images created by *live_images* phase
|
* ``live`` -- for images created by *live_images* phase
|
||||||
|
* ``dvd`` -- for images created by *createiso* phase
|
||||||
|
|
||||||
Default values are the same as the keys.
|
Default values are the same as the keys.
|
||||||
|
|
||||||
@ -271,6 +272,7 @@ Example
|
|||||||
disc_types = {
|
disc_types = {
|
||||||
'boot': 'netinst',
|
'boot': 'netinst',
|
||||||
'live': 'Live',
|
'live': 'Live',
|
||||||
|
'dvd': 'DVD',
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -54,6 +54,7 @@ class CreateisoPhase(PhaseBase):
|
|||||||
def run(self):
|
def run(self):
|
||||||
iso = IsoWrapper(logger=self.compose._logger)
|
iso = IsoWrapper(logger=self.compose._logger)
|
||||||
symlink_isos_to = self.compose.conf.get("symlink_isos_to", None)
|
symlink_isos_to = self.compose.conf.get("symlink_isos_to", None)
|
||||||
|
disc_type = self.compose.conf.get('disc_types', {}).get('dvd', 'dvd')
|
||||||
deliverables = []
|
deliverables = []
|
||||||
|
|
||||||
commands = []
|
commands = []
|
||||||
@ -64,7 +65,7 @@ class CreateisoPhase(PhaseBase):
|
|||||||
self.compose.log_info("Skipping createiso for %s.%s due to config option" % (variant, arch))
|
self.compose.log_info("Skipping createiso for %s.%s due to config option" % (variant, arch))
|
||||||
continue
|
continue
|
||||||
|
|
||||||
volid = get_volid(self.compose, arch, variant, disc_type='dvd')
|
volid = get_volid(self.compose, arch, variant, disc_type=disc_type)
|
||||||
os_tree = self.compose.paths.compose.os_tree(arch, variant)
|
os_tree = self.compose.paths.compose.os_tree(arch, variant)
|
||||||
|
|
||||||
iso_dir = self.compose.paths.compose.iso_dir(arch, variant, symlink_to=symlink_isos_to)
|
iso_dir = self.compose.paths.compose.iso_dir(arch, variant, symlink_to=symlink_isos_to)
|
||||||
@ -90,9 +91,8 @@ class CreateisoPhase(PhaseBase):
|
|||||||
for disc_num, iso_data in enumerate(split_iso_data):
|
for disc_num, iso_data in enumerate(split_iso_data):
|
||||||
disc_num += 1
|
disc_num += 1
|
||||||
|
|
||||||
# XXX: hardcoded disc_type
|
|
||||||
filename = self.compose.get_image_name(arch, variant,
|
filename = self.compose.get_image_name(arch, variant,
|
||||||
disc_type="dvd",
|
disc_type=disc_type,
|
||||||
disc_num=disc_num)
|
disc_num=disc_num)
|
||||||
iso_path = self.compose.paths.compose.iso_path(arch,
|
iso_path = self.compose.paths.compose.iso_path(arch,
|
||||||
variant,
|
variant,
|
||||||
|
Loading…
Reference in New Issue
Block a user