简体   繁体   English

高山无法满足的约束:缺少包裹

[英]Alpine unsatisfiable constraints: missing packages

I am trying to create a docker image based on alpine:3.7 , but I get errors while installing some packages with apk add . 我正在尝试基于alpine:3.7创建一个docker镜像,但是在安装一些带有apk add软件包时出现错误。

Example: 例:

ERROR: unsatisfiable constraints:
  apache2-suexec (missing):
    required by: world[apache2-suexec-custom]
  host (missing):
    required by: world[host]
  lpr (missing):
    required by: world[lpr]
  time (missing):
    required by: world[time]

The cause is that these packages do not exist in alpine repositories yet. 原因是这些软件包在高山存储库中尚不存在。 How can I solve these issues? 我该如何解决这些问题? Is there any repository from which I can download them? 有没有可以从中下载它们的存储库?

I'm using this line 我正在使用这条线

FROM alpine:3.7

RUN apk update \
    && apk upgrade \
    && apk --no-cache add --update tcl apache2 apache2-suexec ca-certificates \ 
    apk-tools curl build-base supervisor lpr time dcron host rsync libxml2-utils libxslt

You have an issue with the following packages: apache2-suexec , host , lpr and time . 您对以下软件包有问题: apache2-suexechostlprtime

Alpine has some other package structure than main Linux OSs: 除了主要的Linux操作系统外,Alpine还具有其他一些软件包结构:

  • apache2-suexec is a part of apache2 package; apache2-suexecapache2软件包的一部分;
  • host is a part of bind-tools package; hostbind-tools软件包的一部分;
  • lpr is a part of cups-client package; lprcups-client软件包的一部分;
  • time is already in alpine image. time已经在高山中了。 It uses busybox 's time utility. 它使用busyboxtime实用程序。

So, the final Dockerfile is: 因此,最终的Dockerfile是:

FROM alpine:3.7

RUN apk update \
    && apk upgrade \
    && apk --no-cache add --update tcl apache2 ca-certificates \ 
    apk-tools curl build-base supervisor cups-client dcron bind-tools rsync libxml2-utils libxslt

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM