Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall
diff options
context:
space:
mode:
authorAnton Hvornum <anton.feeds+github@gmail.com>2020-08-31 16:41:38 +0200
committerAnton Hvornum <anton.feeds+github@gmail.com>2020-08-31 16:41:38 +0200
commit2e7bd45267d141ca5205a10f468d5b5eb8bce668 (patch)
tree9069d4774af3252c0f20ebfa7914181a32a532a7 /archinstall
parent75e2fb4bd3079365d1cff1c6cfccd0c2c2698269 (diff)
Made btrfs optional in the minimal_installation. As it's only required if the filesystem is actually btrfs.
Diffstat (limited to 'archinstall')
-rw-r--r--archinstall/lib/installer.py14
1 files changed, 12 insertions, 2 deletions
diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py
index 5b72ca66..28b51d4e 100644
--- a/archinstall/lib/installer.py
+++ b/archinstall/lib/installer.py
@@ -30,11 +30,13 @@ class Installer():
:type hostname: str, optional
"""
- def __init__(self, partition, boot_partition, *, profile=None, mountpoint='/mnt', hostname='ArchInstalled'):
+ def __init__(self, partition, boot_partition, *, base_packages='base base-devel linux linux-firmware efibootmgr nano', profile=None, mountpoint='/mnt', hostname='ArchInstalled'):
self.profile = profile
self.hostname = hostname
self.mountpoint = mountpoint
+ self.base_packages = base_packages.split(' ')
+
self.partition = partition
self.boot_partition = boot_partition
@@ -108,7 +110,15 @@ class Installer():
return self.run_command(cmd)
def minimal_installation(self):
- self.pacstrap('base base-devel linux linux-firmware btrfs-progs efibootmgr nano'.split(' '))
+ ## Add nessecary packages if encrypting the drive
+ ## (encrypted partitions default to btrfs for now, so we need btrfs-progs)
+ ## TODO: Perhaps this should be living in the function which dictates
+ ## the partitioning. Leaving here for now.
+ if self.partition.filesystem == 'btrfs':
+ #if self.partition.encrypted:
+ self.base_packages.append('btrfs-progs')
+
+ self.pacstrap(self.base_packages)
self.genfstab()
with open(f'{self.mountpoint}/etc/fstab', 'a') as fstab: