Skip to content

Commit 5f4284d

Browse files
committed
don't warn when autodetect is enabled
Signed-off-by: Zen <[email protected]>
1 parent 354fc30 commit 5f4284d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ugrd/crypto/cryptsetup.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
__author__ = 'desultory'
2-
__version__ = '1.5.4'
2+
__version__ = '1.5.5'
33

44
from zenlib.util import check_dict
55

@@ -67,7 +67,8 @@ def _validate_cryptsetup_config(self, mapped_name: str, config: dict) -> None:
6767
if config.get('uuid'):
6868
raise ValueError("A UUID cannot be used with a detached header: %s" % mapped_name)
6969
elif not any([config.get('partuuid'), config.get('uuid'), config.get('path')]):
70-
self.logger.warning("A device uuid, partuuid, or path must be specified for cryptsetup mount: %s" % mapped_name)
70+
if not self['autodetect_root_luks']:
71+
raise ValueError("A device uuid, partuuid, or path must be specified for cryptsetup mount: %s" % mapped_name)
7172

7273

7374
def _process_cryptsetup_multi(self, mapped_name: str, config: dict) -> None:

0 commit comments

Comments
 (0)