snapcraft-managed lxd containers do not respect parallel installs

Bug #1985409 reported by Alex Lewontin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Snapcraft
New
Undecided
Unassigned

Bug Description

In the case when multiple instances of snapcraft are installed in parallel (https://snapcraft.io/docs/parallel-installs) instances suffixed with an instance key (e.g. _foo) appear to install the unsuffixed instance from the host into their managed lxd container. This then results in build failure.

Steps to reproduce:

1) enable parallel installs as described here: https://snapcraft.io/docs/parallel-installs
2) run `snap install snapcraft --channel=6.x/stable --classic` (revision 7201 at reporting time)
3) run `snap install snapcraft_7 --channel=7.x/stable --classic` (revision 8093 at reporting time)
4) initialize a fresh snap using `snapcraft init` and change the base to core22
5) try to run `snapcraft_7` to build that snap

$ snapcraft_7
Launching instance...
Usage: snapcraft pack [OPTIONS] DIRECTORY
Try 'snapcraft pack -h' for help.

Error: No such option: --build-for
Failed to execute pack in instance.
Full execution log: '/home/alex/.cache/snapcraft/log/snapcraft-20220811-135653.968445.log'

Execution log attached to bug report
Lines of interest: 63, 66

I have not tested this using other permutations of versions across parallel installs, or using multipass

Revision history for this message
Alex Lewontin (alexclewontin) wrote :
description: updated
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.