My current understanding of the workflow of creating snaps using snapcraft 3.x is to (transparently) use multipass to do the entire build process on a VM. snapcraft drops the resulting snap in your project directory and you can install it.
How about the snap try feature that was illustrated in the Create your first snap walkthrough?
snap try requires access to the prime directory which is now on a separate machine. Am I missing something or is there a slick trick that I don’t know about or is snap try not currently usable when running snapcraft using multipass?
I was wondering the same, and tried the following with success:
Build your snap with multipass, resulting in a my-snap-name_version_arch.snap file
Execute unsquashfs <my-snap-name_version_arch>.snap to unpack your snap to a new subdirectory named squashfs-root (use -d prime to unpack your snap to a directory prime)
Run snap try squashfs-root (or just snap try if you unpacked to prime)
@Lin-Buo-Ren because that would be a lot of unnecessary traffic between your host and the instance. You rarely need all the intermediate build artifacts, most often you need the resulting .snap file, and so only the source is mounted into the instance. I know it’s on the roadmap to bring back the snap try capability in some way.