parent
91ed69fa44
commit
ca53512f9f
17
Dockerfile
17
Dockerfile
@ -191,9 +191,24 @@ RUN rm -rf pkg/obj && \
|
|||||||
|
|
||||||
FROM scratch AS final
|
FROM scratch AS final
|
||||||
COPY --from=core-busybox / /
|
COPY --from=core-busybox / /
|
||||||
COPY --from=build-make /rootfs/ /
|
|
||||||
COPY --from=build-binutils /rootfs/ /
|
COPY --from=build-binutils /rootfs/ /
|
||||||
COPY --from=build-gcc /rootfs/ /
|
COPY --from=build-gcc /rootfs/ /
|
||||||
COPY --from=build-linux-headers /rootfs/ /
|
COPY --from=build-linux-headers /rootfs/ /
|
||||||
COPY --from=build-musl /rootfs/ /
|
COPY --from=build-musl /rootfs/ /
|
||||||
|
COPY --from=build-make /rootfs/ /
|
||||||
COPY --from=build-go /rootfs/ /
|
COPY --from=build-go /rootfs/ /
|
||||||
|
|
||||||
|
RUN mkdir -p /usr/bin /usr/lib && \
|
||||||
|
[ -L /bin ] && [ -d /bin ] && \
|
||||||
|
[ -L /lib ] && [ -d /lib ] && \
|
||||||
|
[ -L /lib64 ] && [ -d /lib64 ] && \
|
||||||
|
[ -L /usr/lib64 ] && [ -d /usr/lib64 ] && \
|
||||||
|
[ ! -e /sbin ] || [ -z "$(ls -A /sbin 2>/dev/null)" ] && \
|
||||||
|
[ ! -e /usr/sbin ] || [ -z "$(ls -A /usr/sbin 2>/dev/null)" ] && \
|
||||||
|
rm -rf /sbin && \
|
||||||
|
rm -rf /usr/sbin && \
|
||||||
|
ln -sT usr/bin /sbin && \
|
||||||
|
ln -sT bin /usr/sbin
|
||||||
|
|
||||||
|
FROM scratch
|
||||||
|
COPY --from=final / /
|
||||||
|
Loading…
x
Reference in New Issue
Block a user