Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UID mapping logic breaks devpod on MacOS Docker Desktop #1462

Closed
gjhenrique opened this issue Dec 9, 2024 · 1 comment · Fixed by #1463
Closed

UID mapping logic breaks devpod on MacOS Docker Desktop #1462

gjhenrique opened this issue Dec 9, 2024 · 1 comment · Fixed by #1463
Labels

Comments

@gjhenrique
Copy link
Contributor

gjhenrique commented Dec 9, 2024

What happened?

In #1284 and #1287, you fixed the bug with UIDs not maching in the host and container. Good one 🏆!

But this broke MacOS when using devpod in the recent versions. This is because the containers we're building expect the uid to be 1000, including some files from the prebuilt image. The mapping from user 501 breaks this expectation

In #1287, @pascalbreuninger suggested to limit to Linux, which was a good idea, but the PR excluded windows. The check should be runtime.GOOS == "linux" instead of runtime.GOOS =! "windows"`

What did you expect to happen instead?

MacOS Docker Desktop doesn't have any uid mapping, so the logic of rewriting the uid of the container is not necessary

How can we reproduce the bug? (as minimally and precisely as possible)

Use a container that sets a different USER, and doesn't rewrite the original UID

Local Environment:

  • DevPod Version: versions at least 0.5.22
  • Operating System: mac
  • ARCH of the OS: user reported had a mac amd64, but I could reproduce with an ARM mac

DevPod Provider:

  • Local/remote provider: docker

Anything else we need to know?
Opened #1463 to fix that

@pascalbreuninger
Copy link
Member

@gjhenrique Thanks a lot! I forgot to make sure we include this only on linux as per the devcontainer spec

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants