Fix wrong patch on glibc-busybox

because distroless/cc doesn't contain libz
This commit is contained in:
Fahmi Akbar Wildana 2019-09-09 16:45:55 +07:00
parent 62e6cc4dae
commit 9dc58247e5
2 changed files with 12 additions and 6 deletions

View File

@ -1,12 +1,15 @@
ARG base ARG base
FROM gcr.io/distroless/cc AS patch FROM debian:stable-slim AS patch
FROM ${base} FROM ${base}
ARG artifact ARG artifact
COPY ${artifact} /bin/ COPY ${artifact} /bin/
COPY --from=patch /lib/x86_64-linux-gnu/libz* /lib/x86_64-linux-gnu/ COPY --from=patch \
COPY --from=patch /lib/x86_64-linux-gnu/libdl* /lib/x86_64-linux-gnu/ /lib/x86_64-linux-gnu/libz.so.1 \
COPY --from=patch /lib/x86_64-linux-gnu/librt* /lib/x86_64-linux-gnu/ /lib/x86_64-linux-gnu/libdl.so.2 \
COPY --from=patch /lib/x86_64-linux-gnu/libgcc_s* /lib/x86_64-linux-gnu/ /lib/x86_64-linux-gnu/librt.so.1 \
/lib/x86_64-linux-gnu/libgcc_s.so.1 \
/lib/x86_64-linux-gnu/
ENTRYPOINT ["/bin/nu"] ENTRYPOINT ["/bin/nu"]

View File

@ -5,5 +5,8 @@ FROM ${base}
ARG artifact ARG artifact
COPY ${artifact} /bin/ COPY ${artifact} /bin/
COPY --from=patch /lib/x86_64-linux-gnu/libz.so.1 /lib/x86_64-linux-gnu/libz.so.1 COPY --from=patch \
/lib/x86_64-linux-gnu/libz.so.1 \
/lib/x86_64-linux-gnu/
ENTRYPOINT ["/bin/nu"] ENTRYPOINT ["/bin/nu"]