criu/scripts/build/Dockerfile.tmpl
Kir Kolyshkin 02340d167e Dockerfile.tmpl: merge apt-get lines
As recommended by [1], "Always combine RUN apt-get update with apt-get
install in the same RUN statement". Also, ditch "apt-get clean", as it
seems to be useless.

[1] https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices/

https://travis-ci.org/kolyshkin/criu/builds/173168198
Cc: Andrei Vagin <avagin@virtuozzo.com>
Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com>
2016-11-12 11:05:59 +03:00

27 lines
795 B
Cheetah

ARG CC=gcc
RUN apt-get update && apt-get install -y \
build-essential \
protobuf-c-compiler \
libprotobuf-c0-dev \
libprotobuf-dev \
bsdmainutils \
protobuf-compiler \
python-minimal \
libaio-dev \
libcap-dev \
iptables \
libnl-3-dev \
libselinux-dev \
pkg-config \
git-core \
$CC
COPY . /criu
WORKDIR /criu
RUN make mrproper
RUN make -j $(nproc) CC=$CC criu/parasite-syscall.o
RUN make -j $(nproc) CC=$CC
RUN make mrproper
RUN bash -c 'CLEAN="$(git clean -ndx --exclude=scripts/build --exclude=.config)"; echo "${CLEAN}"; test -z "${CLEAN}"; exit $?'