#!/bin/bash # ^^ not compatible on purpose, this only runs inside debian function info { echo "INFO DEB:" "$@" } export PATH="/usr/local/bin:/usr/bin:/bin" export HOME=/root export LC_ALL=C info "Hello from debian!" info "Setting up mounts" mount none -t proc /proc mount none -t sysfs /sys mount none -t devpts /dev/pts info "Configuring the system" echo "debian-image" > /etc/hostname cat < /etc/apt/sources.list deb http://deb.debian.org/debian/ bullseye main contrib non-free deb-src http://deb.debian.org/debian/ bullseye main contrib non-free deb http://deb.debian.org/debian/ bullseye-updates main contrib non-free deb-src http://deb.debian.org/debian/ bullseye-updates main contrib non-free deb http://deb.debian.org/debian-security bullseye-security main deb-src http://deb.debian.org/debian-security bullseye-security main EOF cat < /etc/fstab # /etc/fstab: static file system information. # # Use 'blkid' to print the universally unique identifier for a # device; this may be used with UUID= as a more robust way to name devices # that works even if disks are added and removed. See fstab(5). # # /dev/sda2 / ext4 errors=remount-ro 0 1 /dev/sda1 /boot ext4 defaults 0 2 EOF apt-get update apt-get install -y apt-utils apt-get install -y systemd-sysv