mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-10-30 14:23:52 +00:00
This includes the bug fix that was causing output to be lost much of the time. fix #1660 Signed-off-by: Justin Cormack <justin.cormack@docker.com>
29 lines
948 B
Docker
29 lines
948 B
Docker
FROM linuxkit/alpine:d0cef04aa75159e373fa08a49478ed6bf4adb9b4@sha256:4d8e181db968645b8b3308d2fe725e6f7bb9d9d44a9c3c7782e86c02a6d9e0f1 as alpine
|
|
RUN \
|
|
apk add \
|
|
btrfs-progs-dev \
|
|
gcc \
|
|
git \
|
|
go \
|
|
libc-dev \
|
|
linux-headers \
|
|
make \
|
|
&& true
|
|
ENV GOPATH=/root/go
|
|
ENV CONTAINERD_COMMIT=b53105ed253b99f8b63809e704f23819dce9776e
|
|
RUN mkdir -p $GOPATH/src/github.com/containerd && \
|
|
cd $GOPATH/src/github.com/containerd && \
|
|
git clone https://github.com/containerd/containerd.git
|
|
WORKDIR $GOPATH/src/github.com/containerd/containerd
|
|
RUN git checkout $CONTAINERD_COMMIT
|
|
RUN make binaries GO_GCFLAGS="-buildmode pie --ldflags '-extldflags \"-fno-PIC -static\"'"
|
|
RUN cp bin/containerd bin/ctr bin/containerd-shim bin/dist /usr/bin/
|
|
WORKDIR /
|
|
COPY . .
|
|
|
|
FROM scratch
|
|
ENTRYPOINT []
|
|
WORKDIR /
|
|
COPY --from=alpine /usr/bin/containerd /usr/bin/ctr /usr/bin/containerd-shim /usr/bin/
|
|
COPY --from=alpine /etc/containerd/config.toml /etc/containerd/
|