Wrong variable name in usage

This commit is contained in:
Anton Hvornum 2022-02-09 14:45:08 +01:00
parent e30290aee0
commit 1fdb64858c
No known key found for this signature in database
GPG Key ID: F1234C5BA67C59DF
2 changed files with 5 additions and 4 deletions

View File

@ -143,6 +143,7 @@ def get_arguments():
"""
config = {}
args, unknowns = parser.parse_known_args()
# preprocess the json files.
# TODO Expand the url access to the other JSON file arguments ?
if args.config is not None:
@ -175,6 +176,7 @@ def get_arguments():
# avoiding a compatibility issue
if 'dry-run' in config:
del config['dry-run']
return config
def load_config():

View File

@ -123,12 +123,11 @@ class Filesystem:
else:
loopdev = f"{storage.get('ENC_IDENTIFIER', 'ai')}{pathlib.Path(partition['device_instance'].path).name}"
print(storage['arguments'])
partition['device_instance'].encrypt(
password=partition['!password'],
key_size=storage['arguments']['crypt-key-size'],
hash_type=storage['arguments']['crypt-hash-type'],
iter_time=storage['arguments']['crypt-iter-time']
key_size=storage['arguments']['crypt_key_size'],
hash_type=storage['arguments']['crypt_hash_type'],
iter_time=storage['arguments']['crypt_iter_time']
)
# Immediately unlock the encrypted device to format the inner volume
with luks2(partition['device_instance'], loopdev, partition['!password'], auto_unmount=True) as unlocked_device: