Add fsck before mounting (#56)

Respect all options from systemd-fsck as that it what is currently used
on kairos.

Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
This commit is contained in:
Itxaka
2023-02-17 16:15:26 +01:00
committed by GitHub
parent c081f987f8
commit 5dde396331
3 changed files with 55 additions and 1 deletions

View File

@@ -116,6 +116,10 @@ func (s *State) MountOP(what, where, t string, options []string, timeout time.Du
MountOption: mountPoint,
FstabEntry: *tmpFstab,
Target: where,
PrepareCallback: func() error {
_ = internalUtils.Fsck(what)
return nil
},
}
err = op.run()