microsoft / vscode-docker

Docker Extension for Visual Studio Code
https://marketplace.visualstudio.com/items?itemName=ms-azuretools.vscode-docker
Other
1.18k stars 508 forks source link

VS-code docker extention tells me docker is not installed .... #4317

Closed olterman closed 20 hours ago

olterman commented 3 weeks ago

Docker is installed and working as per the installation instructions linked in the extension turorial (have instalkled and unisnstalled both docker and vs-code ultiple times ... I have added user to the docker group, I have changed permission on the docker socket and put in the docker absolute path in settings .... I am so tired of this ... been troubleshooting the last 4 hours and no dice ... pls help

I am on debian trixie, running code 1.90.0, Docker version 26.1.4, build 5650f9b

bwateratmsft commented 3 weeks ago

Can you share a screenshot of the error you're seeing?

olterman commented 3 weeks ago

Sure, here it is ! Screenshot_07-Jun_06-51-03_7548

Screenshot_07-Jun_06-51-45_4274

ehsash commented 3 weeks ago

Same here with Linux 6.8.0-35-generic 35-Ubuntu SMP PREEMPT_DYNAMIC x86_64 x86_64 x86_64 GNU/Linux and flatpak version of vscode (I also resinstalled docker CLI, vscode, vscodium, code, or other versions many time since yesterday when the bug first occurred after the flatpak vscode package update). Since last update, no more connexion to docker from vscode. The bug occurs with or without terminal integration in the settings. The docker command and services are accessible from the terminal in vscode, but the extension doesn't detect it. It breaks also the use of any dev-container.

Version: 1.89.1 Commit: dc96b837cf6bb4af9cd736aa3af08cf8279f7685 Date: 2024-05-07T05:16:23.416Z Electron: 28.2.8 ElectronBuildId: 27744544 Chromium: 120.0.6099.291 Node.js: 18.18.2 V8: 12.0.267.19-electron.0 OS: Linux x64 6.8.0-35-generic

docker extension version : 1.29.1 - 29 April 2024

One thing that could have changed and influence the occurrence of the problem: Previously my settings and extensions for vscode where in ~/.config/Code and ~/.vscode. Since the update, the config seems to have moved at ~/.var/app/com.visualstudio.code/config/Code/User/settings.json

ehsash commented 3 weeks ago

Issue solved (or partly solved, let's say, as it removes the issue for the user but the problem still exists for the users using the flatpak version, see next) using the deb version from Microsoft website instead of flatpak version. With Microsoft version, which is not sandboxed as is the flatpak version, the issue of the docker service not being found by the docker vscode extension is not occuring (@olterman )

olterman commented 3 weeks ago

I am not running flatpak (I was at first in which I got the docker extention to work by adding the path to the mounted host system but there where other problems with the flatpak version which made me switch to the deb version from microsoft.

ehsash commented 3 weeks ago

@olterman so you have the issue with the deb version from Microsoft VSCode website? Do you use docker daemon community install or Docker Desktop? My docker setup:

docker info

Client: Docker Engine - Community Version: 26.1.3 Context: default Debug Mode: false Plugins: buildx: Docker Buildx (Docker Inc.) Version: v0.14.0 Path: /usr/libexec/docker/cli-plugins/docker-buildx compose: Docker Compose (Docker Inc.) Version: v2.27.0 Path: /usr/libexec/docker/cli-plugins/docker-compose

Server: Containers: 5 Running: 0 Paused: 0 Stopped: 5 Images: 27 Server Version: 26.1.3 Storage Driver: overlay2 Backing Filesystem: extfs Supports d_type: true Using metacopy: false Native Overlay Diff: true userxattr: false Logging Driver: json-file Cgroup Driver: systemd Cgroup Version: 2 Plugins: Volume: local Network: bridge host ipvlan macvlan null overlay Log: awslogs fluentd gcplogs gelf journald json-file local splunk syslog Swarm: inactive Runtimes: runc io.containerd.runc.v2 Default Runtime: runc Init Binary: docker-init containerd version: 8b3b7ca2e5ce38e8f31a34f35b2b68ceb8470d89 runc version: v1.1.12-0-g51d5e94 init version: de40ad0 Security Options: apparmor seccomp Profile: builtin cgroupns Kernel Version: 6.8.0-35-generic Operating System: Ubuntu 24.04 LTS OSType: linux Architecture: x86_64 CPUs: XXXXXX Total Memory: XXXXXX GiB Name: XXXXXX ID: 929ca65b-2a3d-47f0-8289-f603e40c60cb Docker Root Dir: /var/lib/docker Debug Mode: false Experimental: false Insecure Registries: 127.0.0.0/8 Live Restore Enabled: false

My hypothesis is that it could come from using the Docker Desktop setup instead of daemon headless version.

bwateratmsft commented 20 hours ago

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

Happy Coding!