Update repositories and all centos packages

Issues related to applications and software problems and general support
Post Reply
fefe75
Posts: 3
Joined: 2022/05/28 09:34:11

Update repositories and all centos packages

Post by fefe75 » 2022/06/07 21:03:23

I am trying to update a docker image. To do this I ran this command:

Code: Select all

RUN apt update && apt upgrade -y
Unfortunately the command gives errors because the image was not created with a Debian or Ubuntu system but with a different OS, perhaps Centos.
With a system like Centos, how do you update the packages and all the system modules? Can you also clean up the system to prevent the used space from growing excessively?
The image I'm manipulating is this:
https://hub.docker.com/layers/pgadmin4/ ... xt=explore
Unfortunately I can't find the OS on which the image is built written.
I've also tried these codes but they don't work.

Code: Select all

RUN yum -y update
RUN yum clean all

User avatar
TrevorH
Site Admin
Posts: 33218
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Update repositories and all centos packages

Post by TrevorH » 2022/06/07 21:55:13

If you have apt installed then you almost certainly don't have CentOS. If you don't have yum then you definitely don't have CentOS.

Do you have an /etc/os-release and if so, what does it contain?
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Post Reply