mirror of
https://github.com/edera-dev/sprout.git
synced 2025-12-19 15:20:17 +00:00
add initial initramfs support, not quite working yet
This commit is contained in:
11
vm/Dockerfile.initramfs
Normal file
11
vm/Dockerfile.initramfs
Normal file
@@ -0,0 +1,11 @@
|
||||
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/sh /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
|
||||
Reference in New Issue
Block a user