#!/bin/sh

drawblip 2 g
drawblip 3 y

echo "--- Linuxrc mounting /rootdisk using up to maximum 512 MB RAM if available"
mount -t tmpfs -o size=512m tmpfs /rootdisk || drawblip 3 r

echo "--- Linuxrc populating /rootdisk"
tar -pxzf /rootdisk.tar.gz || drawblip 3 r

echo "--- Mounting devfs"
mount -t devfs none /rootdisk/dev || mv /tmpdev/* /rootdisk/dev/

echo "--- Pivoting root"
cd /rootdisk
pivot_root . initrd
exec initrd/usr/sbin/chroot . /sbin/init < dev/console > dev/console 2>&1
