Reduce layer count, prevent extra layer size

This commit is contained in:
Joe Groocock 2018-09-04 19:09:16 +01:00
parent 52061d2af8
commit 196dce995d
Signed by: frebib
GPG Key ID: E0B16BEACFBB6A86

View File

@ -109,6 +109,11 @@ RUN ${PREFIX}/sbin/ldconfig -r ${PREFIX} && \
# Copy UTC localtime to output # Copy UTC localtime to output
cp /usr/share/zoneinfo/Etc/UTC etc/ cp /usr/share/zoneinfo/Etc/UTC etc/
# Add default skeleton configuration files
COPY skel/ .
RUN install -dm 1777 tmp && \
chroot . chmod 775 usr/bin/* sbin/*
# ============= # =============
FROM scratch FROM scratch
@ -134,10 +139,6 @@ WORKDIR /
SHELL ["/bin/sh", "-exc"] SHELL ["/bin/sh", "-exc"]
COPY --from=builder /output/ / COPY --from=builder /output/ /
# Add default skeleton configuration files
COPY skel/ /
RUN chmod 1777 /tmp && \
chmod 775 /usr/bin/*
ENV ENV="/etc/profile" ENV ENV="/etc/profile"
ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/bin ENV PATH=/usr/local/sbin:/usr/local/bin:/usr/bin