mirror of
https://github.com/edera-dev/sprout.git
synced 2025-12-19 17:30:17 +00:00
12 lines
542 B
Docker
12 lines
542 B
Docker
FROM alpine:3.22@sha256:4bcff63911fcb4448bd4fdacec207030997caf25e9bea4045fa6c8c44de311d1 AS build
|
|
RUN apk --no-cache add busybox-static
|
|
RUN mkdir -p /tmp/initramfs/bin && cp /bin/busybox.static /tmp/initramfs/bin/busybox && \
|
|
chroot /tmp/initramfs /bin/busybox --install -s /bin && \
|
|
chroot /tmp/initramfs ln -s /bin/init /init && \
|
|
cd /tmp/initramfs && \
|
|
find . | cpio -R 0:0 --ignore-devno --renumber-inodes -o -H newc --quiet > /initramfs && \
|
|
rm -rf /tmp/initramfs
|
|
|
|
FROM scratch AS final
|
|
COPY --from=build /initramfs /initramfs
|