downloading squashfs over http for faster boot

Szymon Karpiński 7 years ago
parent 514ad3bf8b
commit 5ffaf42e5a
  1. 2
      linux/initramfs/download.sh
  2. 3
      tftp/Dockerfile
  3. 11
      tftp/http.xinetd.conf

@ -1,7 +1,7 @@
#!/bin/sh
. /scripts/functions
configure_networking
tftp -g -r root.squashfs 192.168.14.2
wget http://192.168.14.2/root.squashfs
mkdir /mnt
modprobe loop
losetup /dev/loop0

@ -1,4 +1,5 @@
FROM debian:buster
RUN apt update && apt install -y xinetd tftpd-hpa
RUN apt update && apt install -y xinetd tftpd-hpa busybox
COPY tftp.xinetd.conf /etc/xinetd.d/tftp
COPY http.xinetd.conf /etc/xinetd.d/http
CMD ["script", "-c", "/usr/sbin/xinetd -d"]

@ -0,0 +1,11 @@
service http
{
socket_type = stream
protocol = tcp
wait = no
user = root
server = /bin/busybox
server_args = httpd -if -h /tftpboot
port = 80
flags = IPv4
}
Loading…
Cancel
Save