Close device after luksify

This commit is contained in:
mudler 2022-10-06 00:16:03 +02:00
parent 5fbdc4d614
commit 410f8b2ed7

View File

@ -125,6 +125,11 @@ func luksify(label string) error {
return fmt.Errorf("err: %w, out: %s", err, out)
}
out2, err := sh(fmt.Sprintf("cryptsetup close %s", b.Name))
if err != nil {
return fmt.Errorf("err: %w, out: %s", err, out2)
}
return nil
}