mirror of
https://github.com/ceph/go-ceph
synced 2024-12-18 20:35:33 +00:00
containers: Remove the yum update step
In general it is not desirable to blindly update packages as a whole while building another from a base container image. Historically this step was required due to the introduction of version specific installation[1] of packages i.e, we extract the package version that comes with the base container image and try to install the matching development libraries which might be unavailable close to a new release happening in upstream. In order to overcome this short gap we came up with the idea of `yum update`[2] to fetch whatever is the latest and then extract the version for further installation of development libraries. This seemed to work until we discovered a different issue where updated versions for particular dependencies are pushed to standard repositories causing problems[3] during `yum update`. Ceph repositories(and packages) are now more robust and DNF is capable of handling such situations to figure out the new/updated versions for packages even if a match is not found with the already installed package versions. Ideally it can never be the case that matching packages for each version are missing from a particular repository directory(only the links to the directories is supposed to change). Thus in our best interest we avoid running `yum update`. [1] https://github.com/ceph/go-ceph/pull/331 [2] https://github.com/ceph/go-ceph/pull/510 [3] https://github.com/ceph/go-ceph/pull/1038 Signed-off-by: Anoop C S <anoopcs@cryptolab.net>
This commit is contained in:
parent
9a895f96a0
commit
e25a3ebb64
@ -12,7 +12,6 @@ RUN true \
|
||||
&& echo "Check: [ ${CEPH_VERSION} = ${GO_CEPH_VERSION} ]" \
|
||||
&& [ "${CEPH_VERSION}" = "${GO_CEPH_VERSION}" ] \
|
||||
&& (. /etc/os-release ; if [ "$ID" = centos -a "$VERSION" = 8 ]; then find /etc/yum.repos.d/ -name '*.repo' -exec sed -i -e 's|^mirrorlist=|#mirrorlist=|g' -e 's|^#baseurl=http://mirror.centos.org|baseurl=https://vault.centos.org|g' {} \; ; fi ) \
|
||||
&& yum update -y \
|
||||
&& cv="$(rpm -q --queryformat '%{version}-%{release}' ceph-common)" \
|
||||
&& yum install -y \
|
||||
git wget /usr/bin/curl make \
|
||||
|
Loading…
Reference in New Issue
Block a user