snapd icon indicating copy to clipboard operation
snapd copied to clipboard

osutil: introduce verity device resolver

Open sespiros opened this issue 1 year ago • 3 comments

this commit leverages an existing snapd API that allows registration of different resolvers for device mapper devices which currently only supports luks. It introduces a new resolver for device mapper devices for dm-verity. This resolver uses the ID_FS_UUID udev property to map a verity device to its data partition.

This is potentially a more universal approach to solving the same issue https://github.com/snapcore/snapd/pull/14180 attempted to solve with a workaround.

Jira: https://warthogs.atlassian.net/browse/FR-8353

sespiros avatar Jul 23 '24 17:07 sespiros

Everyone contributing to this PR have now signed the CLA. Thanks!

github-actions[bot] avatar Jul 26 '24 14:07 github-actions[bot]

I have started https://github.com/canonical/snapd/pull/14358 as an alternative. Ping @sespiros

valentindavid avatar Aug 14 '24 15:08 valentindavid

@zyga Thanks for the comments! I would like to add some context. Since I added this we had several discussions with @valentindavid about it which first concluded with Valentin opening:

  • https://github.com/canonical/snapd/pull/14358

We then discussed some more and concluded that maybe the original reason (checking the disk origin) that makes use of these APIs don't apply anymore so Valentin also opened:

  • https://github.com/canonical/snapd/pull/14392
  • https://github.com/canonical/snapd/pull/14393

I am not sure what is the preferred way forward, should we try and merge the verity resolver for the time being and then consider removing them at a later point?

sespiros avatar Sep 09 '24 10:09 sespiros