Error on install Docker in Fedora 35

I tried to install Docker on Fedora 35 with the following commands:

sudo dnf -y install dnf-plugins-core
sudo dnf config-manager \
    --add-repo \
    https://download.docker.com/linux/fedora/docker-ce.repo
sudo dnf install docker-ce docker-ce-cli containerd.io

But, I got the 404 error for the repository:

errors during downloading metadata for repository ‘docker-ce-stable’:

Status code: 404 for https://download.docker.com/linux/fedora/35/x86_64/stable/repodata/repomd.xml (IP: 13.227.108.44)
Error: Falha ao baixar os metadados do repo. ‘docker-ce-stable’: Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried

Does anyone know how to solve this?

3 Likes

EDIT (Monday 25 October 2021): Update: the repo has been published for Fedora 35 now, so the workaround here is no longer required. Please replace 34 with $releasver in your repository files if you’d made that change.


Hello,

Welcome to the forums.

That’s because docker have not yet made a repository for Fedora 35. So for the time being, you’ll have to use their F34 packages. You’ll need to tweak your /etc/yum.repos.d/docker-ce.repo file to replace $releasever (which on Fedora 35 is 35) with 34.

So, it’ll look like this:

[docker-ce-stable]
name=Docker CE Stable - $basearch
baseurl=https://download.docker.com/linux/fedora/34/$basearch/stable
enabled=1
gpgcheck=1
gpgkey=https://download.docker.com/linux/fedora/gpg
...

I check from time to time to see if docker have made a repo from F35 yet. When that happens, we’ll need to undo this change.

4 Likes

Please follow up this ticket in UPSTREAM Project → Docker GITHUB:

Regards.,

2 Likes

Update: the repo has been published for Fedora 35 now, so the workaround here is no longer required. Please replace 34 with $releasver in your repository files if you’d made that change.

1 Like