Fixing rerun

This commit is contained in:
Anton Hvornum 2019-06-20 16:26:06 +00:00
parent 6dacf539c9
commit 7587f67a70
1 changed files with 4 additions and 2 deletions

View File

@ -572,7 +572,9 @@ if __name__ == '__main__':
print('[E] Failed to setup disk encryption.', o) print('[E] Failed to setup disk encryption.', o)
exit(1) exit(1)
o = b''.join(sys_command('/usr/bin/cryptsetup open {drive}{partition_2} luksdev --key-file {pwfile} --type luks2'.format(**args)).exec()) o = b''.join(sys_command('/usr/bin/file /dev/mapper/luksdev').exec()) # /dev/dm-0
if b'cannot open' in o:
o = b''.join(sys_command('/usr/bin/cryptsetup open {drive}{partition_2} luksdev --key-file {pwfile} --type luks2'.format(**args)).exec())
o = b''.join(sys_command('/usr/bin/file /dev/mapper/luksdev').exec()) # /dev/dm-0 o = b''.join(sys_command('/usr/bin/file /dev/mapper/luksdev').exec()) # /dev/dm-0
if b'cannot open' in o: if b'cannot open' in o:
print('[E] Could not mount encrypted device.', o) print('[E] Could not mount encrypted device.', o)