snapd's mkfs.MakeWithContent() uses the host fakeroot instead of the snap-bundled one in ubuntu-image
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Snappy |
Fix Committed
|
High
|
Unassigned | ||
Ubuntu Image |
Fix Released
|
High
|
Unassigned | ||
snapd |
Fix Committed
|
High
|
Unassigned |
Bug Description
We noticed a regression when trying to run our latest 2.1 ubuntu-image snap on jammy. The image builds fail on the mkfs.ext4 stage with the following error:
Error: Error running mkfs: mkfs.ext4: /snap/core20/
William dug a bit deeper and found that the reason for that is that the wrong fakeroot is used during the mkfs stage. Since ubuntu-image has been re-written in Go and using snap directly, we use the mkfs.MakeWithCo
We suppose this could be fixed by doing a `cmd.Env = os.Environ()` right after preparing the fakeroot call in https:/
How should we proceed? How can we use mkfs.MakeWithCo
Changed in snapd: | |
importance: | Undecided → High |
Changed in ubuntu-image: | |
importance: | Undecided → High |
Changed in ubuntu-image: | |
status: | New → Fix Released |
Changed in snapd: | |
status: | New → Fix Committed |
I belive related snapd changes are: https:/ /github. com/snapcore/ snapd/pull/ 11320 https:/ /github. com/snapcore/ snapd/pull/ 11284