【发布时间】:2019-08-02 20:42:20
【问题描述】:
在 OpenShift 中,我使用的是 rhscl_php-71-rhel7 s2i 基础映像。
我需要安装 rh-php71-php-fpm。 我通常用 Dockerfile 来做这个。
FROM rhscl_php-71-rhel7:latest
USER root
RUN yum-config-manager --enable rhel-server-rhscl-7-rpms \
&& yum install -y -q -v \
rh-php71-php-fpm-7.1.8-1.el7.x86_64 \
&& yum clean all \
&& rm -rf /var/cache/yum
USER 1001
但是由于依赖项安装失败,一个较新的包已经存在。
部分日志:
Resolving Dependencies
--> Running transaction check
---> Package rh-php71-php-fpm.x86_64 0:7.1.8-1.el7 will be installed
...
rh-php71-php-fpm-7.1.8-1.el7.x86_64 requires: systemd-sysv
--> Processing Dependency: systemd-sysv for package: rh-php71-php-fpm-7.1.8-1.el7.x86_64
...
TSINFO: Marking systemd-sysv-219-62.el7_6.2.x86_64 as install for rh-php71-php-fpm-7.1.8-1.el7.x86_64
--> Running transaction check
---> Package systemd-sysv.x86_64 0:219-62.el7_6.2 will be installed
Checking deps for systemd-sysv.x86_64 0:219-62.el7_6.2 - u
...
systemd-sysv-219-62.el7_6.2.x86_64 requires: systemd = 219-62.el7_6.2
--> Processing Dependency: systemd = 219-62.el7_6.2 for package: systemd-sysv-219-62.el7_6.2.x86_64
Searching pkgSack for dep: systemd
Potential resolving package systemd-219-62.el7_6.2.x86_64 has newer instance installed.
--> Finished Dependency Resolution
Dependency Process ending
Error: Package: systemd-sysv-219-62.el7_6.2.x86_64 (rhel-7-server-rpms)
Requires: systemd = 219-62.el7_6.2
Installed: systemd-219-62.el7_6.3.x86_64 (@anaconda/7.6)
systemd = 219-62.el7_6.3
尽管存在较新的依赖项,是否有任何选项可以安装软件包?
【问题讨论】:
-
这个图片名称
rhscl_php-71-rhel7:latest可能是错字,我认为它是rhscl/php-71-rhel7:latest。
标签: php dependencies package dockerfile openshift