Skip to content

Allow Loading Attached Container Configs from the Current Project Repository #4584

Open

Description

@thomas-j-moffett

It would be ideal to have the Attached Container config files specified in the current project repository that can be easily shared with a team. https://code.visualstudio.com/docs/remote/attach-container#_attached-container-configuration-files

In my scenario, I am using Lando for my local dev, and I'm not looking to switch any time soon. However, I would like to take advantage of things like smart PHP intellisense, which only seems possible while running in a container (or having PHP installed on my local machine, which I prefer not to do). Since I already have containers running in Lando with one of them running PHP, I would like to attach to that container, but I want the settings for that attached container to come from my project repository automatically.

I imagine this would be similar to how you support the .devcontainer/.devcontainer.json to be located in the project repository. It would be awesome if you could add support for the named container configs as well to be optionally loaded from there instead of from the user's VSCode settings. Maybe add support for giving priority to the current project repo to load a named container config before checking the user settings.

My goal would be able to store those settings in my project repo so I can easily share with the team and have them loaded from there when attaching to the running container.

I guess I can do some manual set up in Lando to get settings files where I need them on those containers, but since VSCode already has the core pieces of this feature, it'd best handled there.

Activity

  1. thomas-j-moffett commented on Mar 2, 2021

    @thomas-j-moffett
    Author

    It would also be ideal if there would be an option or something to force the settings to be written every time you attach to a container.

    I see a potential scenario where someone updates the settings in the project repo (most likely with agreement from the team), and you want those settings to automatically get loaded when you attach to your container. I can also see the flip side of that where you might not want the settings automatically loaded each time you attach. So, a setting to let the user control how that happens would be good.

  2. added
    containers
    on Mar 2, 2021
  3. added
    feature-request
    on Mar 5, 2021
  4. nightpool commented on Jul 28, 2025

    @nightpool

    This is a really important feature request for us, it'll be a huge upgrade to be able to keep these in the workspace-level configuration so we can share it between the team with the rest of our docker-compose file and similar.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

containersfeature-request

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions