Add an argument to rootfs.py to preseed bootstrap with binary packages.

This commit is contained in:
Andrius Štikonas 2022-05-28 22:59:42 +01:00
parent 0b3782d61b
commit d84bb236a4
2 changed files with 9 additions and 2 deletions

View file

@ -34,7 +34,7 @@ class SysA(SysGeneral):
self.sysb_dir = sysb_dir
self.sysc_tmp = sysc_tmp
def prepare(self, mount_tmpfs, copy_sysc, create_initramfs):
def prepare(self, mount_tmpfs, copy_sysc, create_initramfs, repo_path):
"""
Prepare directory structure for System A.
We create an empty tmp directory, unpack stage0-posix.
@ -54,6 +54,10 @@ class SysA(SysGeneral):
if copy_sysc:
self.sysc()
if repo_path:
repo_dir = os.path.join(self.tmp_dir, 'usr', 'src', 'repo-preseeded')
shutil.copytree(repo_path, repo_dir)
if create_initramfs:
self.make_initramfs()