Skip to content

Commit

Permalink
alpine: update to 3.21
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperMaxusa authored and copy committed Jan 2, 2025
1 parent 21310a0 commit a347ff4
Showing 1 changed file with 6 additions and 17 deletions.
23 changes: 6 additions & 17 deletions tools/docker/alpine/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,29 +1,18 @@
FROM docker.io/i386/alpine:3.20.0
FROM docker.io/i386/alpine:3.21.0

ENV KERNEL=lts
ENV KERNEL=virt
ENV ADDPKGS=nodejs

RUN apk add openrc alpine-base agetty alpine-conf $ADDPKGS

RUN if [ "$KERNEL" == "lts" ]; then \
apk add linux-lts \
linux-firmware-none \
linux-firmware-sb16; \
else \
apk add linux-$KERNEL; \
fi
RUN apk add openrc alpine-base agetty alpine-conf linux-$KERNEL linux-firmware-none $ADDPKGS

RUN sed -i 's/getty 38400 tty1/agetty --autologin root tty1 linux/' /etc/inittab
RUN echo 'ttyS0::respawn:/sbin/agetty --autologin root -s ttyS0 115200 vt100' >> /etc/inittab
RUN echo "root:" | chpasswd

RUN setup-hostname localhost

# Adding networking.sh script (works only on lts kernel yet)
RUN if [ "$KERNEL" == "lts" ]; then \
echo -e "rmmod ne2k-pci && modprobe ne2k-pci\nhwclock -s\nsetup-interfaces -a -r" > /root/networking.sh && \
chmod +x /root/networking.sh; \
fi
# Adding networking.sh script
RUN echo -e "rmmod ne2k-pci && modprobe ne2k-pci\nhwclock -s\nsetup-interfaces -a -r" > /root/networking.sh && chmod +x /root/networking.sh

RUN echo 'console.log("Hello, world!");' > /root/hello.js

Expand All @@ -33,4 +22,4 @@ RUN for i in hwclock modules sysctl hostname syslog bootmisc; do rc-update add $
RUN rc-update add killprocs shutdown

# Generate initramfs with 9p modules
RUN mkinitfs -F "ata base ide scsi virtio ext4 9p" $(cat /usr/share/kernel/$KERNEL/kernel.release)
RUN mkinitfs -F "base virtio 9p" $(cat /usr/share/kernel/$KERNEL/kernel.release)

0 comments on commit a347ff4

Please sign in to comment.