Maaz Zindani

Loading the index…

↑↓ move↵ openesc close4072 pages
Servers, nginx and Docker

Docker Desktop .deb will not install on Ubuntu: docker-ce-cli not installable

Errordocker-ce-cli not installable

Short answer

Docker Desktop's package needs Docker's own apt repository, which a bare machine does not have. Add the repository from the Docker Engine install guide, run apt update, check you are on a supported 64-bit Ubuntu, remove conflicting packages, then install the downloaded .deb with apt.

  • Applies to Docker Desktop for Linux (current), Ubuntu 24.04 LTS, x86-64
  • Updated
  • By Maaz Zindani, Senior Software Engineer

Fix it fast

  1. 1Find out which cause you have

    See whether Docker's repository is configured, what Ubuntu you run and on which architecture.

    cat /etc/apt/sources.list.d/docker.sources
    . /etc/os-release && echo "$VERSION_ID"
    dpkg --print-architecture
  2. 2Match what you see, then jump to its fix

    1. 1The first command in the check says no such file, and apt cannot find docker-ce-cli.Docker's apt repository is not set upFix
    2. 2dpkg prints something other than amd64, or the release is not in Docker's supported list.Unsupported Ubuntu release or CPU architectureFix
    3. 3apt reports unmet dependencies or conflicts naming docker.io, containerd or runc.Conflicting Docker packages from the distributionFix

What does the error look like?

  • docker-ce-cli not installable
  • N: Download is performed unsandboxed as root, as file '/home/user/Downloads/docker-desktop.deb'

Cause 1 of 3

Docker's apt repository is not set up

1Check

The Docker Desktop page tells you to set up Docker's package repository first and refers to the apt repository steps of the Engine guide.

apt-cache policy docker-ce-cli

2Fix

Add the key and the repository exactly as the Engine guide shows, then refresh the package index.

sudo apt update
sudo apt install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
sudo tee /etc/apt/sources.list.d/docker.sources <<EOF
Types: deb
URIs: https://download.docker.com/linux/ubuntu
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
Components: stable
Architectures: $(dpkg --print-architecture)
Signed-By: /etc/apt/keyrings/docker.asc
EOF
sudo apt update

3Verify

apt now knows a candidate version, and the Desktop package installs.

apt-cache policy docker-ce-cli
sudo apt install ./docker-desktop-amd64.deb

Confirmed by docs.docker.com

Did this fix it?

Cause 2 of 3

Unsupported Ubuntu release or CPU architecture

1Check

Docker Desktop for Ubuntu requires an x86-64 system with Ubuntu 26.04 LTS or 24.04 LTS. The Engine repository itself supports only 64-bit Ubuntu releases that Docker lists.

dpkg --print-architecture
lsb_release -a

2Fix

Move to a supported release and architecture, or install Docker Engine alone on machines that do not meet the Desktop requirements.

sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

3Verify

Engine commands work.

sudo docker run hello-world

Confirmed by docs.docker.com

Did this fix it?

Cause 3 of 3

Conflicting Docker packages from the distribution

1Check

Ubuntu can ship unofficial Docker packages that clash with Docker's own. The Engine guide says to remove them, and any separately installed containerd and runc, because Docker's packages bring containerd.io.

dpkg --get-selections | grep -E 'docker|containerd|runc'

2Fix

Remove the conflicting packages, then repeat the install.

sudo apt remove $(dpkg --get-selections docker.io docker-compose docker-compose-v2 docker-doc docker-buildx podman-docker containerd runc | cut -f1)
sudo apt install ./docker-desktop-amd64.deb

3Verify

Desktop installs and the docker command runs.

docker version

Confirmed by docs.docker.com

Did this fix it?

How do I stop it coming back?

  • Follow the Engine apt repository steps before any Docker Desktop .deb install.
  • Keep one source of Docker packages on a machine; do not mix docker.io with Docker's repository.
  • Install gnome-terminal if you are not on GNOME, as the Docker Desktop page requires.

Sources

How was this page made?

I drafted this page with AI assistance from the official documents listed under Sources. Every cause above names the document that confirms it. I have not reproduced this fix on a machine of my own yet, so read it as documented guidance, not a test report. Found a mistake? Tell me.

Which stack is behind this page?

Projects of mine built on the same technologies:

Related fixes

Servers

A dev container port does not open in the browser when Docker runs on a remote host

If your application only accepts calls from localhost, it will reject connections from published ports

Three things usually break it: the app listens only on localhost inside the container, so published ports are rejected; you open the container port instead of the mapped localhost port VS Code shows; or you changed appPort or a Compose ports list and did not rebuild.

3 causes, each with a fix

Next step

Want this handled for good?

I look after servers, apps and releases end to end. Tell me what keeps breaking.