首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法在Docker容器中安装ntopng (rfkill问题)

无法在Docker容器中安装ntopng (rfkill问题)
EN

Stack Overflow用户
提问于 2017-07-29 06:23:41
回答 1查看 480关注 0票数 0

下面是我得到的错误:

代码语言:javascript
复制
/var/lib/dpkg/info/rfkill.postinst: 5: /var/lib/dpkg/info/rfkill.postinst: udevadm: not found
dpkg: error processing package rfkill (--configure):
 subprocess installed post-installation script returned error exit status 127

和:

代码语言:javascript
复制
Setting up python3 (3.5.1-3) ...
Setting up lsb-release (9.20160110ubuntu0.2) ...
Setting up dh-python (2.20151103ubuntu1.1) ...
Processing triggers for libc-bin (2.23-0ubuntu9) ...
Processing triggers for ca-certificates (20160104ubuntu1) ...
Updating certificates in /etc/ssl/certs...
173 added, 0 removed; done.
Running hooks in /etc/ca-certificates/update.d...
done.
Errors were encountered while processing:
 rfkill
E: Sub-process /usr/bin/dpkg returned an error code (1)

这是我的Dockerfile:

代码语言:javascript
复制
FROM ubuntu:xenial
MAINTAINER Jean-Nicolas Boulay <jn@yaloub.com>

# Source: http://packages.ntop.org/apt/

RUN export DEBIAN_FRONTEND=noninteractive \
    && export COMPOSER_ALLOW_SUPERUSER=1 \
    && export LC_ALL=C \
    && export LC_ALL="en_US.UTF-8" \
    && export LC_CTYPE="en_US.UTF-8" \
    && export LANGUAGE="en_US:en" \
    && export LANG=C \
    && dpkg --configure -a \
    && apt-get update -qq -y \
    && apt-get install --no-install-recommends --no-install-suggests -y -q \
        apt-utils \
        lsb-release \
        ca-certificates \
        curl \
        wget \
        rfkill \
    && wget http://apt.ntop.org/16.04/all/apt-ntop.deb \
    && dpkg -i apt-ntop.deb \
    && rm -rf apt-ntop.deb \
    && apt-get clean all \
    && apt-get update -qq -y \
    && apt-get upgrade -y \
    && apt-get install --no-install-recommends --no-install-suggests -y -q \
        pfring \
        nprobe \
        ntopng \
        ntopng-data \
        n2disk \
        cento \
        pfring-drivers-zc-dkms \
        nbox \
        redis-server \
        libpcap0.8 \
        libmysqlclient20 \
        python \
        python-pip \
    && python -m pip install --upgrade pip \
    && pip install setuptools \
    && pip install supervisor \
    && apt-get clean \
    && rm -rf /var/lib/apt/lists/* \
    && rm -rf /tmp/* \
    && rm -rf /var/tmp/*

COPY redis.conf /etc/redis/redis.conf
COPY conf/supervisord/supervisord.conf /etc/supervisord.conf

EXPOSE 3000

CMD ["/usr/bin/supervisord"]

那么我该如何用rfkill解决这个问题呢?

EN

回答 1

Stack Overflow用户

发布于 2017-07-29 06:34:40

它似乎正在尝试运行udevadm作为其安装后配置的一部分。

searching ubuntu packages看来,udev包似乎提供了这一点。

只要事先安装了udev,就应该能够安装rfkill。

我能够得到这个dockerfile来构建:

代码语言:javascript
复制
FROM ubuntu:xenial

RUN apt-get update && \
    # Without this line, it did not build properly
    apt-get install -y --no-install-recommends udev && \
    apt-get install -y --no-install-recommends \
        rfkill && \
    apt-get clean
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/45383204

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档