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

CentOS 7/RHEL 7 installations broken where $releasever is '7Server' #1111

Closed
2 tasks done
ineffyble opened this issue Sep 24, 2020 · 64 comments
Closed
2 tasks done

CentOS 7/RHEL 7 installations broken where $releasever is '7Server' #1111

ineffyble opened this issue Sep 24, 2020 · 64 comments

Comments

@ineffyble
Copy link

  • This is a bug report
  • I searched existing issues before opening this one

Expected behavior

yum install is able to install docker-ce from the repo provided at http://download.docker.com/linux/centos/docker-ce.repo when the $releasever variable is set to 7Server.

Actual behavior

At some point in the last week, this has stopped working, and https://download.docker.com/linux/centos/7Server is now a 404. I suspect this coincides with the release of the CentOS 8 packages.

https://download.docker.com/linux/centos/7 still exists, but that is not the same $releasever and so the repo reference in http://download.docker.com/linux/centos/docker-ce.repo is broken.

Steps to reproduce the behavior

Attempt to install Docker from the provided CentOS/RHEL repo with an installation of CentOS/RHEL that has 7Server set as the yum releasever.

@gdhgdhgdh
Copy link

This broke a bunch of deployments for us and caused much yak shaving today. I'd very much appreciate the 7Server being restored.

@thaJeztah
Copy link
Member

Is this both on CentOS and RHEL machines? Does CentOS also set the Server suffix?

@thaJeztah
Copy link
Member

I opened a PR with a workaround for our install script docker/docker-install#194 (but for manual installations, something similar will have to be done);

If you're on RHEL7/CentOS7 and have this issue:

for channel in "stable" "test" "nightly"; do \
    yum-config-manager --setopt="docker-ce-${channel}.baseurl=https://download.docker.com/linux/centos/7/debug-\$basearch/${channel}" --save; \
    yum-config-manager --setopt="docker-ce-${channel}-debuginfo.baseurl=https://download.docker.com/linux/centos/7/debug-\$basearch/${channel}" --save; \
    yum-config-manager --setopt="docker-ce-${channel}-source.baseurl=https://download.docker.com/linux/centos/7/source/${channel}" --save; \
done

If you're on RHEL8/CentOS8 and have this issue:

for channel in "stable" "test" "nightly"; do \
    yum-config-manager --setopt="docker-ce-${channel}.baseurl=https://download.docker.com/linux/centos/8/debug-\$basearch/${channel}" --save; \
    yum-config-manager --setopt="docker-ce-${channel}-debuginfo.baseurl=https://download.docker.com/linux/centos/8/debug-\$basearch/${channel}" --save; \
    yum-config-manager --setopt="docker-ce-${channel}-source.baseurl=https://download.docker.com/linux/centos/8/source/${channel}" --save; \
done

@andrewbanchich
Copy link

I'm experiencing this on RHEL 7.7.

Running your workaround @thaJeztah gives me:

No package docker-ce available.
Error: Nothing to do

@ghost
Copy link

ghost commented Sep 25, 2020

@andrewbanchich The work-around only works if you are using the CentOS version of Docker on RHEL. Red Hat no longer supports Docker so many people switched to using the CentOS version of Docker on RHEL.

Run the CentOS installation instructions on RHEL https://docs.docker.com/engine/install/centos/
But before you $ sudo yum install docker-ce docker-ce-cli containerd.io run the work-around.

One more thing. When switching to the Docker for CentOS watch out for #477

@msbecker
Copy link

I am getting the following error after running the workaround to fix the broken repo link.

sudo yum install docker-ce docker-ce-cli containerd.io Loaded plugins: langpacks, ulninfo
docker-ce-stable | 3.5 kB 00:00:00
ksplice-uptrack | 951 B 00:00:00
ol7_UEKR5 | 2.5 kB 00:00:00
ol7_addons | 2.5 kB 00:00:00
ol7_developer | 2.5 kB 00:00:00
ol7_developer_EPEL | 2.7 kB 00:00:00
ol7_latest | 2.7 kB 00:00:00
ol7_optional_latest | 2.5 kB 00:00:00
ol7_software_collections | 2.5 kB 00:00:00
(1/2): docker-ce-stable/x86_64/updateinfo | 55 B 00:00:00
(2/2): docker-ce-stable/x86_64/primary_db | 6.4 kB 00:00:00
No package docker-ce available.
No package docker-ce-cli available.
No package containerd.io available.
Error: Nothing to do

@ghost
Copy link

ghost commented Sep 25, 2020

@msbecker "ol7" is Oracle Linux 7. Can you please share the output of yum repolist ? Thanks.

@andrewbanchich
Copy link

andrewbanchich commented Sep 25, 2020

@mettacrawler I tried this on a clean RHEL 7.7 server and getting the same results.

When I run the workaround, it outputs

================================================ repo: rhui-rhel-7-server-rhui-rpms ================================================
[rhui-rhel-7-server-rhui-rpms]

followed by a bunch of vars to the console. Then I run the install command:

[ec2-user@ip~]$ sudo yum install docker-ce docker-ce-cli containerd.io
Loaded plugins: amazon-id, search-disabled-repos
docker-ce-stable                                                                                             | 3.5 kB  00:00:00
rhui-client-config-server-7                                                                                  | 2.1 kB  00:00:00
rhui-rhel-7-server-rhui-rh-common-rpms                                                                       | 2.1 kB  00:00:00
rhui-rhel-7-server-rhui-rpms                                                                                 | 2.0 kB  00:00:00
(1/2): docker-ce-stable/x86_64/updateinfo                                                                    |   55 B  00:00:00
(2/2): docker-ce-stable/x86_64/primary_db                                                                    | 6.4 kB  00:00:00
No package docker-ce available.
No package docker-ce-cli available.
No package containerd.io available.
Error: Nothing to do

@ghost
Copy link

ghost commented Sep 25, 2020

@andrewbanchich Did you follow these instructions? https://docs.docker.com/engine/install/centos/

Run the CentOS installation instructions on RHEL https://docs.docker.com/engine/install/centos/
But before you $ sudo yum install docker-ce docker-ce-cli containerd.io run the work-around.

One more thing. When switching to the Docker for CentOS watch out for #477

@andrewbanchich
Copy link

Yes, I followed those instructions and did exactly that. Is the workaround supposed to output those var settings to the console?

@ghost
Copy link

ghost commented Sep 25, 2020

Please try:

sudo yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save

Then
sudo yum install docker-ce docker-ce-cli containerd.io

@andrewbanchich
Copy link

andrewbanchich commented Sep 25, 2020

@mettacrawler After running both commands:

[ec2-user@ip ~]$ sudo yum install docker-ce docker-ce-cli containerd.io
Loaded plugins: amazon-id, search-disabled-repos
docker-ce-stable                                                                                             | 3.5 kB  00:00:00
rhui-client-config-server-7                                                                                  | 2.1 kB  00:00:00
rhui-rhel-7-server-rhui-rh-common-rpms                                                                       | 2.1 kB  00:00:00
rhui-rhel-7-server-rhui-rpms                                                                                 | 2.0 kB  00:00:00
docker-ce-stable/primary_db                                                                                  |  46 kB  00:00:00
Resolving Dependencies
--> Running transaction check
---> Package containerd.io.x86_64 0:1.3.7-3.1.el7 will be installed
--> Processing Dependency: container-selinux >= 2:2.74 for package: containerd.io-1.3.7-3.1.el7.x86_64
---> Package docker-ce.x86_64 3:19.03.13-3.el7 will be installed
--> Processing Dependency: container-selinux >= 2:2.74 for package: 3:docker-ce-19.03.13-3.el7.x86_64
---> Package docker-ce-cli.x86_64 1:19.03.13-3.el7 will be installed
--> Finished Dependency Resolution
Error: Package: 3:docker-ce-19.03.13-3.el7.x86_64 (docker-ce-stable)
           Requires: container-selinux >= 2:2.74
Error: Package: containerd.io-1.3.7-3.1.el7.x86_64 (docker-ce-stable)
           Requires: container-selinux >= 2:2.74
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Update: If I do the follow then it works (again). Thanks @mettacrawler

sudo yum install -y http://mirror.centos.org/centos/7/extras/x86_64/Packages/container-selinux-2.107-3.el7.noarch.rpm
sudo yum install -y https://download.docker.com/linux/centos/7/x86_64/stable/Packages/containerd.io-1.2.6-3.3.el7.x86_64.rpm
sudo yum install -y docker-ce docker-ce-cli

@ghost
Copy link

ghost commented Sep 25, 2020

@andrewbanchich I'm guessing you are stuck with RHEL 7.7 and can't switch to 7.8 for some reason, right?

@andrewbanchich
Copy link

@mettacrawler Correct. Actually I need to use this on 7.6, but I didn't think there would be a huge difference between dot releases.

@ghost
Copy link

ghost commented Sep 25, 2020

@msbecker
Copy link

msbecker commented Sep 25, 2020

Still pointing to wrong URL after running the fix from above.

@mettacrawler
sudo yum repolist
Loaded plugins: langpacks, ulninfo
repo id repo name status
docker-ce-stable/7Server/x86_64 Docker CE Stable - x86_64 17
ksplice-uptrack/7Server/x86_64 Ksplice Uptrack for Oracle Linux 18
nodesource/x86_64 Node.js Packages for Enterprise Linux 7 - x86_64 94
ol7_UEKR5/x86_64 Latest Unbreakable Enterprise Kernel Release 5 for Oracle Linux 7Server (x86_64) 280
ol7_addons/x86_64 Oracle Linux 7Server Add ons (x86_64) 467
ol7_developer/x86_64 Oracle Linux 7Server Development Packages (x86_64) 1,503
ol7_developer_EPEL/x86_64 Oracle Linux 7Server Development Packages (x86_64) 33,021
ol7_latest/x86_64 Oracle Linux 7Server Latest (x86_64) 19,428
ol7_optional_latest/x86_64 Oracle Linux 7Server Optional Latest (x86_64) 14,174
ol7_software_collections/x86_64 Software Collection Library release 3.0 packages for Oracle Linux 7 (x86_64)

@mrhorvath
Copy link

Yeah, I had this same problem on a fresh RHEL 7.8 this afternoon. The workaround of changing the base paths resulted in

yum install -y docker-ce docker-ce-cli containerd.io

Loaded plugins: enabled_repos_upload, package_upload, product-id, search-disabled-repos, subscription-manager
No package docker-ce available.
No package docker-ce-cli available.
No package containerd.io available.
Error: Nothing to do

for me as well.

@jamesoc
Copy link

jamesoc commented Sep 25, 2020

We are using releasever 7.8.
Is there an expectation that this will be fixed in the repo 'in the near term' so that these workarounds are not required?

Regards.

@ghost
Copy link

ghost commented Sep 26, 2020

sudo yum remove docker \
                  docker-client \
                  docker-client-latest \
                  docker-common \
                  docker-latest \
                  docker-latest-logrotate \
                  docker-logrotate \
                  docker-engine
sudo yum install -y yum-utils
sudo yum-config-manager \
     --add-repo \
     https://download.docker.com/linux/centos/docker-ce.repo
sudo yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save
sudo yum install -y http://mirror.centos.org/centos/7/extras/x86_64/Packages/container-selinux-2.107-3.el7.noarch.rpm
sudo yum install -y https://download.docker.com/linux/centos/7/x86_64/stable/Packages/containerd.io-1.2.6-3.3.el7.x86_64.rpm
sudo yum install -y docker-ce docker-ce-cli containerd.io
sudo systemctl enable docker
sudo systemctl start docker
sudo docker run -it --name hello-world --rm hello-world

@msbecker
Copy link

@mettacrawler
I can confirm your latest workaround did the trick. I was able to install docker using those steps.

@ghost
Copy link

ghost commented Sep 27, 2020

We are using releasever 7.8.
Is there an expectation that this will be fixed in the repo 'in the near term' so that these workarounds are not required?

Regards.

Podman give you rootless (not using the root account to run) containers on RHEL 7 right now. Think about the security improvements. https://www.redhat.com/en/blog/rhel-78-and-final-update-container-tools
Podman works with Dockerfiles and Docker repositories, so much of the software there is available and more will be over time.
There's podman-compose intended to be much like docker-compose and it becomes even more like it over time https://github.com/containers/podman-compose
Red Hat will actually support you on Podman (they are no longer supporting Docker).
People are using Podman to do things right now. Better study it early so you're not left behind.

@M0rdecay
Copy link

Any news on this?
We are deploying docker via ansible, using workarounds requires changing roles, which we would like to avoid.

@tonton1728
Copy link

On our side, we are building some docker image with docker inside (inception I know) and we would like not to have to edit repo file in our dockerfile.
As far as I know, creating an alias for 7Server to 7 should do the trick, when can we hope to have a fix ?

@ghost
Copy link

ghost commented Sep 28, 2020

@tonton1728
When I first encountered this issue I was trying to rebuild an AWS AMI via Packer and it crashed trying to install docker-ce. The Ansible that Packer was invoking never tried to install a containerd.io RPM and it worked anyway. If all you are doing is installing a docker-ce RPM then you don't need to download a CentOS container-selinux RPM to support a containerd.io. In that case just changing the docker-ce-stable.baseurl from using $releasever to using a hard-coded 7 will work.

If you need to install a CentOS containerd.io RPM you will also need to install a CentOS container-selinux RPM and doing that is a bit messy.

@jamesoc
Copy link

jamesoc commented Sep 28, 2020

We are using releasever 7.8.
Is there an expectation that this will be fixed in the repo 'in the near term' so that these workarounds are not required?
Regards.

Podman give you rootless (not using the root account to run) containers on RHEL 7 right now. Think about the security improvements. https://www.redhat.com/en/blog/rhel-78-and-final-update-container-tools
Podman works with Dockerfiles and Docker repositories, so much of the software there is available and more will be over time.
There's podman-compose intended to be much like docker-compose and it becomes even more like it over time https://github.com/containers/podman-compose
Red Hat will actually support you on Podman (they are no longer supporting Docker).
People are using Podman to do things right now. Better study it early so you're not left behind.

Thank you @mettacrawler for the response. I will investigate Podman when I have a little breathing room.
Right now, I am not able to execute my ansible script on my hosts that are built with releasever 7.8 and need to get them working in the short term.

My Ansible below breaks on this last step (Install Docker CE) indicating:
https://download.docker.com/linux/centos/7.8/x86_64/stable/repodata/repomd.xml: [Errno 14] Error 404 - Not Found

Just to be clear, this is the replacement for commands?

sudo yum install -y yum-utils
sudo yum-config-manager
--add-repo
https://download.docker.com/linux/centos/docker-ce.repo
sudo yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save
sudo yum install -y http://mirror.centos.org/centos/7/extras/x86_64/Packages/container-selinux-2.107-3.el7.noarch.rpm
sudo yum install -y https://download.docker.com/linux/centos/7/x86_64/stable/Packages/containerd.io-1.2.6-3.3.el7.x86_64.rpm
sudo yum install -y docker-ce docker-ce-cli containerd.io

Thank you,
-Jim O.

@ghost
Copy link

ghost commented Sep 28, 2020

@jamesoc
Please try:
Replace

shell: yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

With

shell: |
    yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
    yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save

@jamesoc
Copy link

jamesoc commented Sep 28, 2020

@jamesoc
Please try:
Replace

shell: yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

With

shell: |
    yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
    yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save

Thank you very much @mettacrawler; I will give that a try. cheers!

@ghost
Copy link

ghost commented Sep 28, 2020

@bitva77
Copy link

bitva77 commented Oct 20, 2020

The fact that this isn't fixed yet makes me feel like Docker did this on purpose in retaliation to RH creating podman.

and now innocent end users are being punished for it.

stay classy every body.

@ghost
Copy link

ghost commented Oct 20, 2020

@gflcampos adding the CentOS repository may cause other RPMs to come from CentOS.

A usable version of the container-selinux RPM is available from certain RHEL and Oracle repositories. If they are available to you, you do not need to use the CentOS container-selinux RPM. You still have to use the CentOS docker-ce RPM from Docker.

First

sudo yum install -y yum-utils

For AWS see https://access.redhat.com/articles/4599971

sudo yum-config-manager --enable rhel-7-server-rhui-extras-rpms

For Azure:

sudo yum-config-manager --enable rhui-rhel-7-server-rhui-extras-rpms

For Oracle Linux 7

sudo yum-config-manager --enable ol7_addons

Then on any of them (see https://docs.docker.com/engine/install/centos/ for most of this.)

sudo yum remove docker \
                  docker-client \
                  docker-client-latest \
                  docker-common \
                  docker-latest \
                  docker-latest-logrotate \
                  docker-logrotate \
                  docker-engine
sudo yum-config-manager \
     --add-repo \
     https://download.docker.com/linux/centos/docker-ce.repo
sudo yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save
sudo yum install -y docker-ce
sudo systemctl enable docker
sudo systemctl start docker
sudo docker run -it --name hello-world --rm hello-world

@bviktor
Copy link

bviktor commented Nov 5, 2020

FYI, on RHEL it's rhel-7-server-extras-rpms.

@rabievdm
Copy link

It looks like the symlinks have been restored, however the webserver is now trying to serve a index.html when using the symlinked version of the url, so it doesn't look like it allows directory browsing on the symlinked URL's eg:
https://download.docker.com/linux/centos/7Server/x86_64/stable/repodata/
However when you change the URL to:
https://download.docker.com/linux/centos/7/x86_64/stable/repodata/

Using the first link you now get:
404 Not Found

Code: NoSuchKey
Message: The specified key does not exist.
Key: linux/centos/7Server/x86_64/stable/repodata/index.html
RequestId: F75B851869AEDF71
HostId: u+9L/FFsIFyJA2g4eZooSHZhbuM5QZDsO6hf5I+XDfEm0Ixr2mc4gK9XKZ+TCi3jIQeAUVXZZWc=

@bviktor
Copy link

bviktor commented Nov 23, 2020

yum doesn't need to "browse" the dirs, it uses predefined files.

@rabievdm
Copy link

Fair, but its still broken when I trying and just do a yum list, so the perms must still be broken.

[root@docdev01 ~]# yum list
https://download.docker.com/linux/centos/7Server/x86_64/stable/repodata/repomd.xml: [Errno 14] HTTPS Error 404 - Not Found
Trying other mirror.

You can recreate the error without yum, just try with wget:
wget https://download.docker.com/linux/centos/7Server/x86_64/stable/repodata/repomd.xml
--2020-11-23 15:27:19-- https://download.docker.com/linux/centos/7Server/x86_64/stable/repodata/repomd.xml
Resolving download.docker.com (download.docker.com)... 143.204.64.100, 143.204.64.9, 143.204.64.159, ...
Connecting to download.docker.com (download.docker.com)|143.204.64.100|:443... connected.
HTTP request sent, awaiting response... 404 Not Found
2020-11-23 15:27:21 ERROR 404: Not Found.

@mrjk
Copy link

mrjk commented Jan 6, 2021

Honestly I feel it's unacceptable that this 4 months old bug is still open. How long does it takes to do a symlink or a 301 http redirect on a web server? I mean this is admin level 0, so what is the technical challenge that need to be accomplished to solve this issue? None.

Well, I feel this is the time to migrate away from Docker because all what we did is now broken (thanks by the way) and require us to workaround in the worst way. What is the point of automating everything if we can't reuse what has been done, isn't the Docker promise ? I don't feel breaking things is the correct way to do for the docker user base, but well, I feel there is a lots of politics behind this choice of not fixing this issue, and I don't feel comfortable with this anymore. Also I don't pay for any service/support so I shouldn't complain, but this bug is a very bad joke.

@Pictor13
Copy link

I fixed the repo URl via:

sed -i 's/$releasever/7/g' /etc/yum.repos.d/docker-ce.repo

according to this forum thread suggestions.

Might help other fix temporary and get work done.

@epijonk
Copy link

epijonk commented Feb 5, 2021

lol.. still not fixed. I just ran into this error.

@bitva77
Copy link

bitva77 commented Feb 5, 2021

haha! what a joke.

long live containerd?!

@Vaccano
Copy link

Vaccano commented Feb 6, 2021

Wow! Since this is apparently not going to get fixed, it desperately needs to get added to the docs. (I lost a lot of time on this.)

If the docs had just said:

There is an open issue that we are still thinking about. Until we decide to fix the redirect to work on the actual file you need, add this call before you run yum install :

sudo yum-config-manager --setopt="docker-ce-stable.baseurl=https://download.docker.com/linux/centos/7/x86_64/stable" --save

(Tongue and cheek added since this is kind of depressing to have a redirect cause so much sadness.)

@chainhead
Copy link

@Vaccano
You have a space between download and .docker.com in value of docker-ce-stable.baseurl.

Fast forward to Mar '21, this problem still exists. I am trying to install docker on an Amazon Linux 2 EC2 instance - which, I believe, is RHEL 7. And, this is what I see after doing the yum-config-manager.

sudo yum install docker-ce docker-ce-cli containerd.io -y
Failed to set locale, defaulting to C

Loaded plugins: extras_suggestions, langpacks, priorities, update-motd
amzn2-core                                                                                                                                     | 3.7 kB  00:00:00     
amzn2extra-docker                                                                                                                              | 3.0 kB  00:00:00     
No package docker-ce available.
No package docker-ce-cli available.
No package containerd.io available.
Error: Nothing to do

@denven
Copy link

denven commented Mar 25, 2021

I got this error and come here, after fixing the broken repo, I got some other dependencies error afterward. Anyway, I installed it finally. If you failed to install docker on Oracle Linux 7.9 or CentOS 7.x ( coz they are alike), check this link:

I wrote a script here, you can use the bash script to install it.

@chaseduffin
Copy link

Still a problem. wtf @docker

@thaJeztah
Copy link
Member

@chaseduffin I think fixes were made for this; are you still running into this issue? What $releaseVer does your machine have?

I just tried to reproduce the problem (quick check in a container);

docker run -it --rm centos:7

Add the repository;

yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

Set 7Server as $releasever to mimic the scenario reported here:

for channel in "stable" "test" "nightly"; do \
    relver=7Server; \
    yum-config-manager --setopt="docker-ce-${channel}.baseurl=https://download.docker.com/linux/centos/$relver/\$basearch/${channel}" --save; \
    yum-config-manager --setopt="docker-ce-${channel}-debuginfo.baseurl=https://download.docker.com/linux/centos/$relver/debug-\$basearch/${channel}" --save; \
    yum-config-manager --setopt="docker-ce-${channel}-source.baseurl=https://download.docker.com/linux/centos/$relver/source/${channel}" --save; \
done

Verify that that worked correct, and that the repository now has 7Server in its repo-URL:

yum repolist -v docker-ce-stable

...

Repo-id      : docker-ce-stable/x86_64
Repo-name    : Docker CE Stable - x86_64
Repo-status  : enabled
Repo-revision: 1618226779
Repo-updated : Mon Apr 12 11:26:19 2021
Repo-pkgs    : 112
Repo-size    : 2.7 G
Repo-baseurl : https://download.docker.com/linux/centos/7Server/x86_64/stable/
Repo-expire  : 21600 second(s) (last: Thu Apr 15 12:14:22 2021)
  Filter     : read-only:present
Repo-filename: /etc/yum.repos.d/docker-ce.repo

Install docker-ce:

yum install -y --quiet docker-ce
warning: /var/cache/yum/x86_64/7/base/packages/audit-libs-python-2.8.5-4.el7.x86_64.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Public key for audit-libs-python-2.8.5-4.el7.x86_64.rpm is not installed
Public key for container-selinux-2.119.2-1.911c772.el7_8.noarch.rpm is not installed
warning: /var/cache/yum/x86_64/7/docker-ce-stable/packages/docker-ce-20.10.6-3.el7.x86_64.rpm: Header V4 RSA/SHA512 Signature, key ID 621e9f35: NOKEY
Public key for docker-ce-20.10.6-3.el7.x86_64.rpm is not installed
Public key for selinux-policy-3.13.1-268.el7_9.2.noarch.rpm is not installed
Importing GPG key 0xF4A80EB5:
 Userid     : "CentOS-7 Key (CentOS 7 Official Signing Key) <security@centos.org>"
 Fingerprint: 6341 ab27 53d7 8a78 a7c2 7bb1 24c6 a8a7 f4a8 0eb5
 Package    : centos-release-7-9.2009.0.el7.centos.x86_64 (@CentOS)
 From       : /etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
Importing GPG key 0x621E9F35:
 Userid     : "Docker Release (CE rpm) <docker@docker.com>"
 Fingerprint: 060a 61c5 1b55 8a7f 742b 77aa c52f eb6b 621e 9f35
 From       : https://download.docker.com/linux/centos/gpg
setsebool:  SELinux is disabled.

Check that things were installed:

docker --version
Docker version 20.10.6, build 370c289
dockerd --version
Docker version 20.10.6, build 8728dd2
containerd --version
containerd containerd.io 1.4.4 05f951a3781f4f2c1911b05e61c160e9c30eaa8e

@creatorKoo
Copy link

creatorKoo commented Apr 15, 2021

@docker guys should feel ashamed that this bug has been open for 4 months. Who is in charge of this issue?

I got little solution about 404.

sudo rm -rf /var/cache/yum/x86_64/7/docker-ce*
yum update
yum install docker-ce

then work for me.

@thaJeztah
Copy link
Member

closing as this should be fixed #1111 (comment)

@rindeastwood
Copy link

rindeastwood commented Jun 11, 2021

Issue still exists on CentOS 8. (CentOS Linux release 8.4.2105)

sudo yum install docker-ce docker-ce-cli containerd.io
repository for docker ce 500 B/s | 382 B 00:00
Errors during downloading metadata for repository 'docker-ce-stable':

Followed the instructions: https://docs.docker.com/engine/install/centos/

@msbecker
Copy link

Given the switch to CentOS Stream, I suspect this may not ever be fixed, at least not soon.

@thaJeztah
Copy link
Member

@rindeastwood what does yum repolist -v docker-ce-stable show for you? That URL it's trying to download looks really wrong (https://download.docker.com/linux/centos/docker-ce.repo is a file)

@johntiger1
Copy link

johntiger1 commented Jul 7, 2021

Still broken for me.

OS details:


NAME="Amazon Linux"
VERSION="2"
ID="amzn"
ID_LIKE="centos rhel fedora"
VERSION_ID="2"
PRETTY_NAME="Amazon Linux 2"
ANSI_COLOR="0;33"
CPE_NAME="cpe:2.3:o:amazon:amazon_linux:2"
HOME_URL="https://amazonlinux.com/"
Amazon Linux release 2 (Karoo)

The solution mentioned here: https://forums.docker.com/t/docker-ce-stable-x86-64-repo-not-available-https-error-404-not-found-https-download-docker-com-linux-centos-7server-x86-64-stable-repodata-repomd-xml/98965/6

worked for me

@thaJeztah
Copy link
Member

@johntiger1 we currently don't have packages for Amazon Linux on download.docker.com, so that's somewhat expected (but good to hear the workaround worked)

@jamshid
Copy link

jamshid commented Sep 18, 2023

NEVERMIND THE REPO FILE IS WORKING NOW.

@thaJeztah this repo file is empty, I assume it should not be. It's causing No package docker-ce-cli available..

[root@df8a58a4f7b9 /]# curl --head -H 'Cache-control: no-cache' https://download.docker.com/linux/centos/docker-ce.repo?foo
HTTP/1.1 200 OK
Content-Type: binary/octet-stream
Content-Length: 0
Connection: keep-alive
Date: Mon, 18 Sep 2023 12:53:28 GMT
Last-Modified: Fri, 15 Sep 2023 23:26:10 GMT
ETag: "d41d8cd98f00b204e9800998ecf8427e"
Server: AmazonS3
X-Cache: Hit from cloudfront
Via: 1.1 aed14b36df96d4ec7e7cb3f8e4883524.cloudfront.net (CloudFront)
X-Amz-Cf-Pop: DFW55-C3
X-Amz-Cf-Id: Et0mUV1kklpkvHhJxZKk3pNMadt_ncgf1JEQpyO6LnZFE_0c96l2Qw==
Age: 7570

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests