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

devcontainer nos honoring dev.containers.dockerComposePath #10087

Closed
jjcasmar opened this issue Jul 22, 2024 · 6 comments
Closed

devcontainer nos honoring dev.containers.dockerComposePath #10087

jjcasmar opened this issue Jul 22, 2024 · 6 comments
Assignees
Labels
containers Issue in vscode-remote containers info-needed Issue requires more information from poster

Comments

@jjcasmar
Copy link

  • VSCode Version: 1.91.1

  • Local OS Version: Linux

  • Remote OS Version: Linux

  • Remote Extension/Connection Type: Containers

  • Logs:

Start: Run: /usr/bin/podman compose --project-name mandos_devcontainer -f /home/jjcasmar/projects/Mandos/.devcontainer/docker-compose.yml -f /tmp/devcontainercli-jjcasmar/docker-compose/docker-compose.devcontainer.containerFeatures-1721642121005-2d9811f9-795d-43f1-b4ac-dca6b518ebae.yml up -d
>>>> Executing external compose provider "/usr/bin/docker-compose". Please refer to the documentation for details. <<<<

WARN[0000] /home/jjcasmar/projects/Mandos/.devcontainer/docker-compose.yml: `version` is obsolete 
WARN[0000] /tmp/devcontainercli-jjcasmar/docker-compose/docker-compose.devcontainer.containerFeatures-1721642121005-2d9811f9-795d-43f1-b4ac-dca6b518ebae.yml: `version` is obsolete 
[+] Running 0/1
 ⠸ Container mandos-dev  Creating                                          0.3s 
Error response from daemon: container create: creating container storage: the container name "mandos-dev" is already in use by b67c8e10d523964bd2d626efa48815a6cc367a30c6eda239106a3d5bbbc12bc0. You have to remove that container to be able to reuse that name: that name is already in use
Error: executing /usr/bin/docker-compose --project-name mandos_devcontainer -f /home/jjcasmar/projects/Mandos/.devcontainer/docker-compose.yml -f /tmp/devcontainercli-jjcasmar/docker-compose/docker-compose.devcontainer.containerFeatures-1721642121005-2d9811f9-795d-43f1-b4ac-dca6b518ebae.yml up -d: exit status 1

Steps to Reproduce:

  1. Setup dev.containers.dockerComposePath= "podman-compose"
  2. Try to run start a devcontainer. Will try to use docker-compose

When I set the dockerComposePath to podman-compose, devcontainer still tries to use docker-compose.

@vs-code-engineering vs-code-engineering bot added the containers Issue in vscode-remote containers label Jul 22, 2024
@chrmarti
Copy link
Contributor

The shows podman compose calling docker-compose. I guess you have to configure podman compose to either error out (in which case the Dev Container CLI will use the configured dev.containers.dockerComposePath) or to call podman-compose.

@chrmarti chrmarti added the info-needed Issue requires more information from poster label Jul 22, 2024
@jjcasmar
Copy link
Author

Is there any way to specify in vscode how podman compose called? Maybe I can add an envvar before calling it

@chrmarti
Copy link
Contributor

You could start VS Code with an env variable set. Or: Add it to your local .bashrc (or similar file for your shell).

@jjcasmar
Copy link
Author

Starting vscode witht the envar set is not an option. VSCode is connected to a remote session via ssh, and is in that ssh session where I want to start a devcontainer.

Setting PODMAN_COMPOSE_PROVIDER=podman-compose in zshrc (in the ssh remote server) is not working. I guess the file is not read when the session is open

@chrmarti
Copy link
Contributor

Please append the Dev Containers log from when this happens. (F1 > Dev Containers: Show Container Log)

It should read env variables from your default shell.

Copy link

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.

Happy Coding!

@vs-code-engineering vs-code-engineering bot closed this as not planned Won't fix, can't repro, duplicate, stale Jul 30, 2024
@vs-code-engineering vs-code-engineering bot locked and limited conversation to collaborators Sep 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
containers Issue in vscode-remote containers info-needed Issue requires more information from poster
Projects
None yet
Development

No branches or pull requests

2 participants