Attempting to fix auto-detection of encrypted drives. So that #124 can perform reverse detection on partitions and detect encryption.
This commit is contained in:
parent
bd134c5db0
commit
5099376dcd
|
|
@ -214,6 +214,10 @@ class Partition():
|
|||
|
||||
self._encrypted = value
|
||||
|
||||
@property
|
||||
def parent(self):
|
||||
return self.real_device
|
||||
|
||||
@property
|
||||
def real_device(self):
|
||||
if not self._encrypted:
|
||||
|
|
|
|||
|
|
@ -283,8 +283,9 @@ class Installer():
|
|||
if '/usr/bin/btrfs-progs' not in BINARIES:
|
||||
BINARIES.append('/usr/bin/btrfs')
|
||||
|
||||
elif partition.encrypted and 'encrypt' not in HOOKS:
|
||||
HOOKS.insert(HOOKS.find('filesystems'), 'encrypt')
|
||||
elif (partition.encrypted or Partition(partition.parent, None).filesystem == 'crypto_LUKS'):
|
||||
if 'encrypt' not in HOOKS:
|
||||
HOOKS.insert(HOOKS.find('filesystems'), 'encrypt')
|
||||
|
||||
self.pacstrap(self.base_packages)
|
||||
self.helper_flags['base-strapped'] = True
|
||||
|
|
|
|||
|
|
@ -1,5 +1,9 @@
|
|||
import archinstall
|
||||
|
||||
# Unmount and close previous runs
|
||||
archinstall.sys_command(f'umount -R /mnt', suppress_errors=True)
|
||||
archinstall.sys_command(f'cryptsetup close /dev/mapper/luksloop', suppress_errors=True)
|
||||
|
||||
# Select a harddrive and a disk password
|
||||
archinstall.log(f"Minimal only supports:")
|
||||
archinstall.log(f" * Being installed to a single disk")
|
||||
|
|
|
|||
Loading…
Reference in New Issue