Containers should use the current user where possible
Metadata
Current evaluation
Root-owned LXD build artifacts were fixed by corrected UID mapping in merged canonical/snapcraft#1904 (commit 6bd4c9e59).
Resolution: —
Evaluated by: mr-cal-bot
No scores available.
Issue body
Using `SNAPCRAFT_CONTAINER_BUILDS=1 snapcraft` your dir is littered with root-owned folders, it's a pain to have to clean it up with sudo.
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | — | Root-owned LXD build artifacts were fixed by corrected UID mapping in merged canonical/snapcraft#1904 (commit 6bd4c9e59). | |
| stealth/space-bunny-alpha | — | closed resolved | Root-owned build artifacts were fixed by correcting LXD user-ID mapping in merged PR #1904 (commit 6bd4c9e59). | |
| stealth/space-bunny-alpha | — | closed stale | Closed as stale after nine years without a linked fix, implementation, or maintainer explanation; no change was made specifically for this report. | |
| stealth/space-bunny-alpha | — | closed stale | Report about root-owned directories created by container builds was closed without an identified fix, superseding change, or maintainer explanation. | |
| qwen/qwen3.6-35b-a3b | — | — | Closed without a fix or implementation. The report about snapcraft containers generating root-owned directories was left unresolved due to inactivity, with zero comments and no resolution details provided. | |
| qwen/qwen3.6-35b-a3b | — | — | The request to run snapcraft containers as the current user to prevent root-owned folders was closed without resolution. Lacking comments or patches, the issue was abandoned. |
Update history
| Date | Change |
|---|---|
| created |
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1847 lxd: Use user in container when mounting remote via sshfs | snapcraft | merged | Merged as commit e7d73a365: snapcraft now creates a user in the LXD container for remote sshfs builds so project files aren't left root-owned, fixing LP bug #1741082. | |
| #1700703 container builds fail after creating the container | snapcraft (launchpad) | closed | LXD container-build ID mapping was fixed by snapcore/snapcraft#1385, merged as commit e85e0779b, removing the assumption that the user's UID was 1000. |