mirror of
https://git.launchpad.net/livecd-rootfs
synced 2025-06-09 17:11:35 +00:00
live-build: move snap seed validation into snap_preseed
This commit is contained in:
parent
ac717bff40
commit
248efab2fd
@ -88,11 +88,6 @@ preinstall_snaps() {
|
|||||||
snap_preseed chroot "${snap}"
|
snap_preseed chroot "${snap}"
|
||||||
done
|
done
|
||||||
lb chroot_resolv remove
|
lb chroot_resolv remove
|
||||||
|
|
||||||
# Do basic validation of generated snapd seed.yaml.
|
|
||||||
if [ -e chroot/var/lib/snapd/seed/seed.yaml ]; then
|
|
||||||
snap debug validate-seed chroot/var/lib/snapd/seed/seed.yaml
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
rm -f binary.success
|
rm -f binary.success
|
||||||
|
@ -635,6 +635,15 @@ snap_preseed() {
|
|||||||
touch "$CHROOT_ROOT/var/lib/snapd/seed/.snapd-explicit-install-stamp"
|
touch "$CHROOT_ROOT/var/lib/snapd/seed/.snapd-explicit-install-stamp"
|
||||||
;;
|
;;
|
||||||
esac
|
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/var/lib/snapd/seed/seed.yaml
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
snap_from_seed() {
|
snap_from_seed() {
|
||||||
@ -892,4 +901,4 @@ replace_kernel () {
|
|||||||
install --assume-yes "${new_kernel}"
|
install --assume-yes "${new_kernel}"
|
||||||
env DEBIAN_FRONTEND=noninteractive chroot "${mountpoint}" apt-get \
|
env DEBIAN_FRONTEND=noninteractive chroot "${mountpoint}" apt-get \
|
||||||
autoremove --purge --assume-yes
|
autoremove --purge --assume-yes
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user