Snapcraft ignores SNAPCRAFT_BUILD_ENVIRONMENT_* environment variables on MacOS
Metadata
Current evaluation
Documented SNAPCRAFT_BUILD_ENVIRONMENT_CPU/MEMORY are ignored on macOS; maintainer confirms Multipass CPU/memory hardcoded and points to upstream craft-providers#531. Docs still promise the vars work.
Suggested action: keep open
Reason: Confirmed valid and already triaged (labels 'Status: Triaged', 'Type: Enhancement'; internal tickets SNAPCRAFT-1293/SNAPCRAFT-1294). Maintainer @mr-cal stated 'CPU and memory for Multipass is hardcoded without a workaround' and linked the outstanding upstream task craft-providers#531, which is still open, so nothing in snapcraft resolves this — but it must not be closed. Repo evidence confirms the gap: docs/how-to/set-up-snapcraft.rst still tells users to 'export SNAPCRAFT_BUILD_ENVIRONMENT_CPU=8 / _MEMORY=16G' (lines 147-148), while snapcraft/providers.py:325-326 simply returns a bare MultipassProvider() with no CPU/memory plumbing, and no commit touches these vars. The in-repo portion (correcting the stale tip, which also references core20 despite core20 being dropped in #6019) is actionable now, which is why actionability is moderate rather than high; the real fix is blocked upstream.
Evaluated by: mr-cal-bot
Issue body
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha |
Impact:
45
Quick Win:
14
Complexity:
50
Confidence:
85
Actionability:
62
|
keep open | Documented SNAPCRAFT_BUILD_ENVIRONMENT_CPU/MEMORY are ignored on macOS; maintainer confirms Multipass CPU/memory hardcoded and points to upstream craft-providers#531. Docs still promise the vars work. | |
| qwen/qwen3.6-35b-a3b |
Impact:
40
Quick Win:
16
Complexity:
50
Confidence:
90
Actionability:
80
|
keep open | SNAPCRAFT_BUILD_ENVIRONMENT_CPU and SNAPCRAFT_BUILD_ENVIRONMENT_MEMORY env vars are ignored on macOS with Multipass; maintainer confirmed CPU/memory are hardcoded and referenced craft-providers#531 as the blocking task. | |
| qwen/qwen3.8-27b |
Impact:
45
Quick Win:
25
Staleness:
55
Complexity:
45
Confidence:
82
Support Request:
25
|
keep open | SNAPCRAFT_BUILD_ENVIRONMENT_CPU/MEMORY env vars documented for Multipass VM sizing are ignored on macOS; maintainer confirmed values are hardcoded, fix blocked by upstream craft-providers#531 (open 2+ years). Triaged as enhancement, no progress since Feb 2026. | |
| qwen/qwen3.6-35b-a3b |
Staleness:
55
Complexity:
40
Confidence:
90
Support Request:
10
|
keep open | Snapcraft on macOS ignores SNAPCRAFT_BUILD_ENVIRONMENT_* variables for Multipass VM resources. Maintainer confirmed it is hardcoded and linked to an uncompleted enhancement task. Currently triaged and awaiting implementation. | |
| qwen3.6-35b-a3b-mtp-q6 |
Staleness:
65
Complexity:
60
Confidence:
85
Support Request:
20
|
keep open | User reports SNAPCRAFT_BUILD_ENVIRONMENT_* vars are ignored on macOS when using Multipass. Maintainer confirmed it is hardcoded and linked to an upstream tracking issue. Awaiting implementation. |
Update history
No update history recorded yet.
Related work
-
Blocked By:
canonical/craft-providers#531
(confidence 95%)
Explicitly cited by maintainer @mr-cal; open enhancement 'Provide a way to set Multipass CPU and memory' where MultipassProvider still hardcodes cpus=2/mem_gb=2.
-
Duplicate Of:
snapcraft (launchpad)#2008003
(confidence 70%)
Same defect tracked on Launchpad ('Multipass build provider does not support resource settings core core22 snaps'), also pointing at craft-providers#531.
-
Related To:
snapcraft (launchpad)#1814729
(confidence 65%)
Older Launchpad report of SNAPCRAFT_BUILD_ENVIRONMENT_MEMORY/ CPU being ignored when an existing Multipass instance is reused; same root cause.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1814729 Setting SNAPCRAFT_BUILD_ENVIRONMENT_MEMORY doesn't take effect | snapcraft (launchpad) | open | Feature request: SNAPCRAFT_BUILD_ENVIRONMENT_MEMORY/CPU are ignored when an existing Multipass VM is reused; maintainer confirmed the vars only apply at VM creation and advised purging the instance. Not implemented | |
| #2008003 Multipass build provider does not support resource settings core core22 snaps | snapcraft (launchpad) | open | Multipass builds of core22+ snaps ignore SNAPCRAFT_BUILD_ENVIRONMENT_CPU/MEMORY; provider hardcodes 2 CPUs/2GB RAM. Maintainer confirmed unsupported; fix tracked upstream in craft-providers#531. | |
| #1822265 SNAPCRAFT_BUILD_ENVIRONMENT_* change doesn't apply to existing VMs | snapcraft (launchpad) | closed | Closed by maintainer sergiusens (2019-04-17) as intended behaviour: SNAPCRAFT_BUILD_ENVIRONMENT_* are development/debugging-only variables, so no change was made to apply them to an existing Multipass VM. | |
| #1809068 SNAPCRAFT_ environment variables not exposed to version-script | snapcraft (launchpad) | closed | Closed after maintainers directed users from version-script to snapcraftctl set-version; no fix was cited for the missing SNAPCRAFT_* variables. |