diff options
| author | delusionalai <delusionalai@users.noreply.git.jnsn.dev> | 2026-11-16 22:09:56 +0000 |
|---|---|---|
| committer | delusionalai <delusionalai@users.noreply.git.jnsn.dev> | 2026-11-16 22:09:56 +0000 |
| commit | e237acf0f5161db48b9553db541e91e02b191f97 (patch) | |
| tree | fc80717c81eea2fa071839d5368b24374dd88afc /template.sh | |
| parent | 83b26ae8184c4e3ab5a62021f371d2d656fb72ae (diff) | |
| download | devbox-e237acf0f5161db48b9553db541e91e02b191f97.tar.gz devbox-e237acf0f5161db48b9553db541e91e02b191f97.zip | |
login.sh: put the graphroot on a filesystem overlayfs can live on
Podman's overlay storage driver cannot be built on virtiofs, which is what the
graphroots sit on in a kata guest, so nested podman fails with "mount overlay:
invalid argument". The loop-mounted ext4 that was supposed to fix it never
happened, for two independent reasons:
- `df -PT "$STORAGE"` runs before anything has created $STORAGE, and df exits 1
on a nonexistent path, so the test is never true. mkdir -p was inside the if.
- even when df did answer, `cut -d' ' -f2` returns an empty string, because df
separates its columns with runs of spaces rather than single ones.
Once it does fire, three more things go wrong: truncate and mkfs run
unconditionally, so every start wipes every image and container; the ext4 is
root-owned, so the dev user gets EACCES on its own graphroot; and a failed
--make-rshared is swallowed with `|| true`, which leaves nested containers
without the shared mount propagation they need.
Also covers 9p, fuse, nfs, cifs and an overlay root, all of which need the loop
just as much as virtiofs does, and treats ext*/xfs/btrfs/f2fs/tmpfs as the
native case they are.
Co-Authored-By: pi <pi@pi.dev>
Diffstat (limited to 'template.sh')
0 files changed, 0 insertions, 0 deletions
