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

devcontainers: "ENOENT: no such file or directory" when trying to build Laravel Sail container #10085

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

Comments

@parapente
Copy link

  • VSCode Version: 1.91.1
  • Local OS Version: Ubuntu Linux 24.04
  • Remote Extension/Connection Type: Containers

Steps to Reproduce:

  1. curl -s "https://laravel.build/example-app?with=mariadb,mailpit&devcontainer" | bash
  2. cd example-app && code .
  3. Try to reopen in container

There is no problem when trying either ./vendor/bin/sail up or using the devcontainers/cli and running devcontainer build --workspace-folder .

% devcontainer --version
0.57.0

remoteContainers-2024-07-20T16-47-32.155Z.log

The problem seems to be with the relative path of the context property in docker-compose.yml. It doesn't use the project root path but the path from the extension. This used to work correctly in previous versions of vscode and the remote extension. I tested it in vscode-insiders and it still doesn't work. I also tested both with docker-compose and docker with builderx and got the same error message.

@vs-code-engineering vs-code-engineering bot added the containers Issue in vscode-remote containers label Jul 20, 2024
@parapente
Copy link
Author

Some more notes:

I tested vscode 1.90, even with a clean profile (removed ~/.vscode and ~/.config/Code), but it still doesn't work. I also tried the previous versions of the remote extension from this year but they give the same error message.

What works:
If I use the cli devcontainer command devcontainer up --workspace-folder . and then try to reconnect from vscode to the container, it works just fine.

@chrmarti
Copy link
Contributor

Could you update to a more recent Docker Compose? The log shows:

[2024-07-20T16:47:33.693Z] Stop (73 ms): Run: docker compose version --short
[2024-07-20T16:47:33.693Z] Docker Compose version: v2.0.1

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

I tested it with the latest docker-ce version and it wouldn't work. I'll retest and upload the new log.

@parapente
Copy link
Author

Log with docker-ce
remoteContainers-2024-07-22T12-36-21.496Z.log

@chrmarti
Copy link
Contributor

The new log still shows the old version: Docker Compose version: v2.0.1. You might need to update a separate package.

@parapente
Copy link
Author

@chrmarti you are correct. I had an old version of the docker compose plugin installed in ~/.docker/cli-plugins which was taking precedence on any new install and I didn't even remember installing. Thank you for your help.

@vs-code-engineering vs-code-engineering bot locked and limited conversation to collaborators Sep 6, 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