Commit Graph

1 Commits

Author SHA1 Message Date
Olivier Gayot 217ac98fc6 filesystem: mount snapd/seed/systems only if it exists
The "$source"/var/lib/snapd/seed/systems directory only exists in certain
scenarios related to TPM-backed FDE. When the directory does not exist,
attempting to bind-mount it to /var/lib/snapd/seed/systems crashes the
install with a CalledProcessError.

We now make sure the directory exists before trying to mount it. For
dry-run test cases, we added a configuration item that simulates the
presence (or the non-presence) of the systems directory on the source.

Signed-off-by: Olivier Gayot <olivier.gayot@canonical.com>
2022-11-25 15:50:01 +01:00