Eclipse IDE docker tooling - Cannot create connection to Docker

I am using Ubuntu 24.04 and developing C/C++ programs using Eclipse IDE [2025-03].
I am doing cross development and my development tools require ubuntu 20.04
I have setup Docker desktop/engine as described in:
Ubuntu | Docker Docs
Docker runs fine and I have established a container with the pre-requite Ubuntu that works as expected.
Docker desktop is version 28.0.1

In eclipse I have added the Docker tooling, and changed to the Docker perspective.
Eclipse indicates there is no connection to a docker daemon so I click to create a new connection.

Problem 1: Eclipse now asks me for:
connection name. If I use search, it says I need to set preferences for the docker-machine

Running “$ docker info” on Ubuntu says the root directory for Docker is /var/lib/docker and
systemctl says Docker is running as /usr/lib/systemd/system/docker.service

Eclipse asks where the docker-machine command is located, but eclipse indicates both the above directories don’t have the docker-machine command.

??? what directories do UI use for the docker machine and for the VM Driver ?

Problem 2: Eclipse also asks to provide the unix socket for docker.
Running “$ docker info” on Ubuntu I get:
com.docker.desktop.address=unix:///home/lachlan/.docker/desktop/docker-cli.sock

If I use this address and test the connection, it says “ping failed”. but I notice it tries to ping unix://localhost:80

??? Can anyone help me how to set the connection in eclipse so I can get access to the docker containers?

1 Like

It must be a rather outdated eclipse extension, if it depends on docker machine, which was deprecated ~4 years ago.

I just tried it on WSL2 Ubuntu: the extension doesn’t seem to like Docker Desktop.
I would suggest raising an issue with the extension maintainer.

As a workaround, you might want to try removing Docker Desktop, and installing docker-ce instead. Make sure to follow the post installation instruction, so that your unprivliged user account will be able to access the docker.sock.

That must be Docker CE, but how did it become Docker Desktop in the next command?

You shared it as “Problem 1” and “Problem 2”

We had topics about Docker Desktop for Windows and Eclipse

I know, you are using Linux, but if Eclipse allows you to use TCP sockets and unix sockets, at least one should work on Linux either with Docker CE or Docker Desktop, and your first post indicates you tried Docker CE.

How did you try @meyay? How does it not like Docker Desktop? :slight_smile:

But I can also try it on a Linux after work tomorrow


The location for the Unix Socket was selected with the file-picker that opens when the “Browse” button is clicked.

I can only imagine that the extension uses an older docker sdk version under the hood, which uses an api version that’s older than the minimal supported api version current docker versions provide.

To resolve the connection issues between Eclipse and Docker on Ubuntu 24.04:

  1. Docker-Machine Issue: Eclipse is looking for Docker Machine, which isn’t typically used with Docker Desktop. Docker Desktop on Ubuntu doesn’t rely on Docker Machine, so you can skip this step. Instead, use the Docker daemon directly by specifying the correct socket path.

  2. Unix Socket Issue: For the Docker socket, use the address provided by your docker info command: unix:///var/run/docker.sock (this is the default). Eclipse tries to use unix://localhost:80, which seems incorrect. Make sure to set the socket to /var/run/docker.sock in Eclipse and test the connection again.

To summarize:

  • For the Docker Machine question, ignore it (no need for a machine).
  • For the Unix socket, use /var/run/docker.sock and verify the connection works.

The docker-cli.sock must be something else. I think it is for communication between the Docker Desktop and the client in the VM. The socket of Docker Desktop’s daemon for the docker client is in $HOME/.docker/desktop/docker.sock. The connection works and containers and images are shown. I still get “Widget is disposed” error messages constantly which unfortunately makes it unusable, but I don’t really know how to use Eclipse properly anymore. Maybe I imade a mistake when I installed Docker tooling. Or there is a bug indeed in it.

You are right. I just noticed the sock in the output of docker info, but missed that it’s just a label, and that the actually used socket is not displayed in the output.

Inside my WSL distribution, this file does not exist. When I list the contexts, the default context is using with unix:///var/run/docker.sock. I have luck with unix:///var/run/docker.sock either.

Maybe that’s the secret sauce. I just opened the view that came preinstalled with Eclipse CPP..

Thanks for the help.
[Note that this forum does not allow me to put in more than two URLs so I have to put in spaces instead of dots and slash’s]

I have set the connection name and unix socket as you have shown in your reply. I found the same socket via the browse button.
When I use the test-connection but, it fails. [PingFailed] and it indicates that a connection was rejected by port 80 on localhost.
I can then only cancel the connection process.

“$ docker info” indicated a http Proxy:
HTTP Proxy: http.docker.interal:3128.
I tried using this in the TCP box, and also tried using localhost with port 3128. Both do not work, but at least Eclipse recognised that I dont want to talk to localhost:80.

I installed docker desktop using the instructions in the URL:
docs.docker.com desktop setup install linux ubuntu

This required me first to install the docker engine as described in the URL:
docs docker com engine install ubuntu
This required me to install the following components:
$ sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

I then installed the desktop using: $ sudo apt install ./docker-desktop-amd64.deb

I dont really need the docker desktop.
I can remove the docker desktop: $ sudo apt remove docker-desktop,
but will that fix the problem?

I am using Eclipse 2025-03.
If I go to the URL :
marketplace eclipse org content eclipse-docker-tooling
it indicates that the docker Tooling in Eclipse is available for version 2025-03, and the reference to docker tooling was updated on Mar-21, 2025. I erased and reloaded Eclipse so I have the latest version as of 1-Apr. [2025-03]

I don’t think there is a problem with privileged accounts because my access to docker via CLI does not require sudo.

Do I revert this problem to Eclipse ?

Thanks for your help

The plugin might be compatible with the Eclipse version, but its implementation itself is outdated: it uses deprecated docker projects: docker-compose v1 was deprecated ~2 years ago, docker machine was deprecated ~4 years ago. This has a strong smell of an unmaintained plugin.

Oddly, the plugin that came bundle with Eclipse IDE for C/C++ Developers didn’t work for me. Installing it from “Install Software” didn’t fix it, but re-installing it from the marketplace finally made it work with unix:///var/run/docker.sock

I installed docker tooling via C/C++ Developers vision and “Install software”.

What did you do to install from marketplace?
Did you uninstall all docker tools from Eclipse then download from this website:
https://marketplace.eclipse.org/content/eclipse-docker-tooling
It says to install you must drag it into the Eclipse workspace, but that does not work.

Eclipse indicate the “Eclipse marketplace client is installed”

I installed it within the IDE: Help → Eclipse Marketplace.

It was already marked as installed, but I installed it anyway. Then Eclipse asked to restart the IDE and then finally the plugin worked.

Did as you suggested and updated docker through marketplace.
Entered the unix socket.
When I ‘test connection’ I get: Permission denied.

I dont need ‘sudo’ to run docker on the command line, but I guess the daemon is different.

Any thoughts?

You are still using a client which needs access to a socket (TCP or UNIX). Try to check logs in Eclipse to see what causes the permission denied message. If you can use the docker command on the same host, you are either using a different docker context which connects to another daemon, or the error message is not about accessing the socket.