# Switch Container option not working after reinstall (WSL + Dev Containers)

**URL:** <https://forum.cursor.com/t/switch-container-option-not-working-after-reinstall-wsl-dev-containers/152698>\
**Category:** Bug Reports\
**Tags:** devcontainers, wsl\
**Created:** [February 23, 2026, 9:23pm UTC](https://forum.cursor.com/t/switch-container-option-not-working-after-reinstall-wsl-dev-containers/152698 "2026-02-23T21:23:01Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![deanrie](https://sea3.discourse-cdn.com/cursor1/user_avatar/forum.cursor.com/deanrie/32/1263_2.png) [@deanrie](https://forum.cursor.com/u/deanrie)\
**Post date:** [February 24, 2026, 9:54am UTC](https://forum.cursor.com/t/switch-container-option-not-working-after-reinstall-wsl-dev-containers/152698/4 "2026-02-24T09:54:31Z")

</div>

Hey, thanks for the detailed report and the logs.

From the logs, the key difference is clear: in WSL the search finds both files, but inside the running container it finds 0. Most likely the `.devcontainer` folder isn’t mounted inside your container.

The Anysphere Dev Containers extension needs the `.devcontainer` directory to be accessible from the running container for the “Switch Container” feature to work. Could you please check:

1. What does `workspaceFolder` look like in your `devcontainer.json` files? Does it point to the project root (where `.devcontainer/` lives) or to a subfolder?
2. Inside the running container, can you confirm that `.devcontainer/` is actually present? Run `ls -la` at the workspace root from the container terminal.

If `workspaceFolder` points to a location that doesn’t include `.devcontainer/`, you may need to adjust the mount so that directory is available inside the container. Related discussion with the same root cause: Anyspheres Dev Container Extension: Switch Containers - [Anyspheres Dev Container Extension: Use the Name Property of DevContainers + Allow to Switch Containers - #7 by ravirahman](https://forum.cursor.com/t/anyspheres-dev-container-extension-use-the-name-property-of-devcontainers-allow-to-switch-containers/103138/7).

Let me know what you find.

---

_[View the full topic](https://forum.cursor.com/t/switch-container-option-not-working-after-reinstall-wsl-dev-containers/152698)._
