Skip to content

Commit

Permalink
Merge pull request #1635 from aledbf/dumb-init-from-distro
Browse files Browse the repository at this point in the history
Install dumb-init using apt-get
  • Loading branch information
aledbf authored Nov 1, 2017
2 parents 71da8aa + 9015aad commit 3ea7464
Showing 1 changed file with 13 additions and 7 deletions.
20 changes: 13 additions & 7 deletions rootfs/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,21 @@ FROM BASEIMAGE

CROSS_BUILD_COPY qemu-QEMUARCH-static /usr/bin/

RUN DEBIAN_FRONTEND=noninteractive apt-get update && apt-get install -y \
diffutils \
--no-install-recommends \
# install dumb-init from zesty
RUN if grep -q -i "ports.ubuntu.com" /etc/apt/sources.list; \
then \
echo "deb http://ports.ubuntu.com/ubuntu-ports zesty universe" >> /etc/apt/sources.list; \
else \
echo "deb http://archive.ubuntu.com/ubuntu zesty universe" >> /etc/apt/sources.list; \
fi \
&& DEBIAN_FRONTEND=noninteractive apt-get update \
&& apt-get install -y \
diffutils \
dumb-init \
--no-install-recommends \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

RUN curl -sSL -o /tmp/dumb-init.deb http://ftp.us.debian.org/debian/pool/main/d/dumb-init/dumb-init_1.2.0-1_DUMB_ARCH.deb && \
dpkg -i /tmp/dumb-init.deb && \
rm /tmp/dumb-init.deb

ENTRYPOINT ["/usr/bin/dumb-init"]

COPY . /
Expand Down

0 comments on commit 3ea7464

Please sign in to comment.