My brother wrote up a nice article about how to run a debian mirror on kubernetes. I wanted to take it a step further and make it easier to configure without having to rebuild the image to add another repo. It needs to store gpg keys and some apt sources.list files to make it easy to use the repo. We will also enable directory browsing with NGINX.
Dockerfile A simple Dockerfile to create the image our cron jobs will use.
Installing Debian can be achieved by using booting your box from the network. This is how I set up my server to allow clients to boot from it.
PXE Configuration This needs to be added to your /tftproot/pxelinux.cfg/default file. Refer to PXE-Linux-Boot-Server on how to set up a PXE server.
label debianbuster-min-vm MENU LABEL ^Debian Autoinstall Buster Minimal VM LINUX /debian/buster/debian-installer/amd64/linux INITRD /debian/buster/debian-installer/amd64/initrd.gz APPEND vga=788 preseed/url=tftp://server/debian/preseed-buster-min-vm.txt debian-installer/locale=en_US debian-installer/country=US debian-installer/language=en debian-installer/allow_unauthenticated_ssl=true keyboard-configuration/xkb-keymap=us netcfg/get_hostname=debian netcfg/get_domain=local.