diff options
Diffstat (limited to 'morphlib')
-rw-r--r-- | morphlib/builder2.py | 5 | ||||
-rw-r--r-- | morphlib/plugins/tarball-systembuilder_plugin.py | 1 |
2 files changed, 4 insertions, 2 deletions
diff --git a/morphlib/builder2.py b/morphlib/builder2.py index 565fdf4f..d3768054 100644 --- a/morphlib/builder2.py +++ b/morphlib/builder2.py @@ -662,8 +662,8 @@ class DiskImageBuilder(SystemKindBuilder): # pragma: no cover with self.build_watch('overall-build'): arch = self.artifact.source.morphology['arch'] - rootfs_artifact = self.new_artifact( - self.artifact.source.morphology['name'] + '-rootfs') + rootfs_name = self.artifact.source.morphology['name'] + '-rootfs' + rootfs_artifact = self.new_artifact(rootfs_name) handle = self.local_artifact_cache.put(rootfs_artifact) (image_file_fd, image_name) = \ tempfile.mkstemp(dir=self.app.settings['tempdir']) @@ -682,6 +682,7 @@ class DiskImageBuilder(SystemKindBuilder): # pragma: no cover factory_path = os.path.join(mount_point, 'factory') self._create_subvolume(factory_path) self.unpack_strata(factory_path) + self.write_metadata(factory_path, rootfs_name) self.create_fstab(factory_path) self._create_bootloader_config(factory_path) self._create_subvolume_snapshot( diff --git a/morphlib/plugins/tarball-systembuilder_plugin.py b/morphlib/plugins/tarball-systembuilder_plugin.py index 95cae4cd..14807924 100644 --- a/morphlib/plugins/tarball-systembuilder_plugin.py +++ b/morphlib/plugins/tarball-systembuilder_plugin.py @@ -49,6 +49,7 @@ class RootfsTarballBuilder(SystemKindBuilder): # pragma: no cover try: fs_root = self.staging_area.destdir(self.artifact.source) self.unpack_strata(fs_root) + self.write_metadata(fs_root, rootfs_name) self.create_fstab(fs_root) self.copy_kernel_into_artifact_cache(fs_root) unslashy_root = fs_root[1:] |