Is it possible to install or run multiple copies of a snap package, each with it's own isolated copy of app config / data?

  • I know it's possible to install two instances of the same snap package, because I've done it, but I don't remember how I did it. I'm posting this comment as a service to anyone who would otherwise post an answer claiming in it that it can't be done. – karel Apr 18 '18 at 11:27
  • Parallel snap installs is listed as upcoming on the snapd roadmap. If you have the snapcraft.yaml then you may be able to do it now by renaming the snap, snapping by setting up LXD then running SNAPCRAFT_CONTAINER_BUILDS=1 snapcraft (not snapcraft cleanbuild), then installing the snap with --dangerous. – Ads20000 Apr 23 '18 at 16:02

It is possible to do parallel installs from version 2.36 of snapd (snap --version), which includes the version on Ubuntu 18.10.

# Enable parallel instances
sudo snap set system experimental.parallel-instances=true

# First instance - normal install (not required)
sudo snap install myapp

# Second or more instances
sudo snap install myapp myapp_two
sudo snap install myapp myapp_three

Not that the instance name must match <snap-name>_<instance-key> - it can't have an arbitrary name.

Documentation: https://forum.snapcraft.io/t/parallel-installs/7679

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.