mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-21 10:09:07 +00:00
tools: Use a multi-stage build for mkimage-iso-bios
mkimage-iso-bios contained the full alpine base. Only copy packages actually needed. Signed-off-by: Rolf Neugebauer <rn@rneugeba.io>
This commit is contained in:
parent
d04a42868f
commit
4ca0458526
@ -1,13 +1,16 @@
|
||||
FROM linuxkit/alpine:daed76b8f1d28cdeeee215a95b9671c682a405dc
|
||||
|
||||
RUN \
|
||||
apk update && apk upgrade && \
|
||||
apk add --no-cache \
|
||||
libarchive-tools \
|
||||
FROM linuxkit/alpine:daed76b8f1d28cdeeee215a95b9671c682a405dc as mirror
|
||||
RUN mkdir -p /out/etc/apk && cp -r /etc/apk/* /out/etc/apk/
|
||||
RUN apk add --no-cache --initdb -p /out \
|
||||
alpine-baselayout \
|
||||
busybox \
|
||||
cdrkit \
|
||||
libarchive-tools \
|
||||
syslinux \
|
||||
&& true
|
||||
RUN mv /out/etc/apk/repositories.upstream /out/etc/apk/repositories
|
||||
|
||||
FROM scratch
|
||||
WORKDIR /
|
||||
COPY --from=mirror /out/ /
|
||||
COPY . .
|
||||
|
||||
ENTRYPOINT [ "/make-iso" ]
|
||||
|
Loading…
Reference in New Issue
Block a user