Closed imjasonh closed 3 months ago
Hey @imjasonh, thanks a lot for the PR, It's a very welcome fix for Wolfi (I've never tried it personally)! We should only have this one area where we do a one-off for alpine and it's only because VSCode Server can't install without these dependencies. Other IDEs should be fine.
Wolfi is a relatively new distro focused on minimalism and fast package updates, in the service of low-to-no-CVE images. Like Alpine, it uses
apk
as its package manager. Unlike Alpine, it's glibc-based, and doesn't use musl.I tried to use devpod to run a Wolfi-based container, and got this error:
Decoding that error, it says:
Looking at the code, it looks like
alpine.go
expects the presence ofapk
to determine whether the image is Alpine, and if so, it installs necessary tools, includinggcompat
. Wolfi, being glibc-based, doesn't includegcompat
(it's a glibc compatibility layer for musl), so this fails.This PR makes the following changes to better support Wolfi-based images:
ID=alpine
in/etc/os-release
to determine ifgcompat
is needed.InstallAlpineRequirements
toInstallAPKRequirements
and rephrase error messages, since it now handles any distro usingapk
as a package manager.Let me know if there's anywhere else I should be looking for Alpine assumptions, I'm happy to send more PRs after this one.