docker - 错误:无法在 docker-dr-elephant 构建中找到匹配项
问题描述
我正在测试 dr-elephant :
但是当我运行时:
docker build -t dr-elephant:2.0.6 .
我越来越
Complete!
Last metadata expiration check: 0:00:19 ago on Thu Oct 24 07:51:21 2019.
No match for argument: krb5-auth-dialog
No match for argument: pam_krb5
Error: Unable to find a match
The command '/bin/sh -c yum install -y wget git unzip zip which && yum install -y krb5-server krb5-libs krb5-workstation && yum install -y krb5-auth-dialog pam_krb5 && yum install -y openssh-server openssh-clients && yum clean all' returned a non-zero code: 1
关于如何解决这个问题的任何想法?
谢谢
解决方案
错误就在那里:yum
无法安装名为pam_krb5
和的软件包krb5-auth-dialog
您可以通过运行centos
映像来轻松测试它并尝试安装这些软件包:
[root@228fcb9e4c19 /]# yum install -y krb5-auth-dialog pam_krb5
Failed to set locale, defaulting to C
CentOS-8 - AppStream 1.1 MB/s | 6.0 MB 00:05
CentOS-8 - Base 2.0 MB/s | 7.9 MB 00:03
CentOS-8 - Extras 634 B/s | 2.1 kB 00:03
No match for argument: krb5-auth-dialog
No match for argument: pam_krb5
Error: Unable to find a match
关于如何解决这个问题......您可以尝试删除该行(Dockerfile 中的第 9 行),但是您如何知道应用程序是否需要这些包?所以你最好的办法是联系所有者并告诉他他的 Dockerfile 不再工作(它已经 2 岁了)。
通常出现此问题是因为基础映像没有固定版本。你可以查看它的 using FROM centos:latest
,但今天的 centos 与两年前的 centos 不一样。您也可以尝试编辑基本映像的标签并使用较旧的 centos 版本,它可能会或可能不会工作。
推荐阅读
- python - 如何停止收到错误消息 self is not defined?
- r - 如何在数据框中编写波斯语(或阿拉伯语)?
- javascript - 如何从 ABC XYZ 中提取 ABC 和 XZ?
- discord - 如何在此脚本中将用户添加到角色?不和谐.js
- documentum - 如何在 DFC documentum 中使用 IDfExportOperation 导出文档的原生内容和再现内容?
- django - 没有为 django-background-tasks 创建表
- java - 为什么我的数组在翻转和反转时显示为 0?
- flask-sqlalchemy - 如何将 SQL 转换为 Flask SQLAlchemy
- flutter - .contains 不像我想象的那样工作 Flutter/Dart
- javascript - 在三元运算符中使用多个条件来停止在特定路由上渲染组件