diff --git a/debian/control b/debian/control index 6358738e..5ea1443b 100644 --- a/debian/control +++ b/debian/control @@ -33,7 +33,7 @@ Depends: ${misc:Depends}, python3-software-properties, qemu-utils, rsync, - snapd, + snapd (>= 2.39), squashfs-tools (>= 1:3.3-1), sudo, u-boot-tools [armhf arm64], diff --git a/live-build/functions b/live-build/functions index 3a558820..0597715c 100644 --- a/live-build/functions +++ b/live-build/functions @@ -579,6 +579,15 @@ snap_preseed() { touch "$CHROOT_ROOT/var/lib/snapd/seed/.snapd-explicit-install-stamp" ;; esac + + + # Do basic validation of generated snapd seed.yaml, doing it here + # means we catch all the places(tm) that snaps are added but the + # downside is that each time a snap is added the seed must be valid, + # i.e. snaps with bases need to add bases first etc. + if [ -e chroot/var/lib/snapd/seed/seed.yaml ]; then + snap debug validate-seed "$CHROOT_ROOT/var/lib/snapd/seed/seed.yaml" + fi } is_live_layer () {