coder / envbuilder

Build development environments from a Dockerfile on Docker, Kubernetes, and OpenShift. Enable developers to modify their development environment quickly.
Apache License 2.0
111 stars 23 forks source link

Error running devcontainer with container registry kubernetes secret volume mounted #225

Closed wazoo closed 1 month ago

wazoo commented 1 month ago

I am experiencing the same bug as mentioned in #119 and #104 but there doesn't seem to be a release that includes those fixes yet, are there any known workarounds for this issue?

Error message:

error: remove docker config: remove /.envbuilder/config.json: device or resource busy

I have tried many different combinations of paths and values for KANIKO_DIR and DOCKER_CONFIG as well and it always seems to try to delete it. I have also tried setting ENVBUILDER_FORCE_SAFE and setting the secret with DOCKER_CONFIG_BASE64 but I couldn't get that to work either (and I would rather not use an env var for safety).

I have not included many details in this issue because it is the same as the other issues but I am happy to provide more information if needed.

Environment: Coder: v2.10.2 Envbuilder: 0.2.9, 0.2.8 (both produce this error) Kubernetes: 1.28.9

It seems like the fix in those other two issues would work and just need to be released, I am trying to avoid having to build a custom version based on main but I can do that if needed to validate.

wazoo commented 1 month ago

I built envbuilder from main and can confirm that it doesn't have this issue in my environment.

johnstcn commented 1 month ago

Hey @wazoo, we're working towards a new release that will include these fixes.

We've also started publishing preview builds here so you don't need to build your own main: https://github.com/coder/envbuilder/pkgs/container/envbuilder-preview