tMount overlayfs on top of squashfs. - uwu - hardware bitcoin wallet software and build system
 (HTM) git clone https://git.parazyd.org/uwu
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) README
 (DIR) LICENSE
       ---
 (DIR) commit e433596e4c8c93c86e0425f9ba39565c04d17b86
 (DIR) parent 03f31396c9577a676ef5af73d337ddb560c7acba
 (HTM) Author: parazyd <parazyd@dyne.org>
       Date:   Wed,  3 Feb 2021 00:49:30 +0100
       
       Mount overlayfs on top of squashfs.
       
       Diffstat:
         M initramfs/init                      |      12 ++++++++----
       
       1 file changed, 8 insertions(+), 4 deletions(-)
       ---
 (DIR) diff --git a/initramfs/init b/initramfs/init
       t@@ -3,7 +3,7 @@ set -x
        
        /bin/busybox --install -s /bin
        
       -mkdir -p /dev /boot /mnt /proc /sys /etc /tmp
       +mkdir -p /dev /boot /mnt/ro /mnt/rw /proc /sys /etc /tmp
        
        touch /etc/fstab
        
       t@@ -16,10 +16,14 @@ mount /dev/mmcblk0p1 /boot
        cp /boot/filesystem.squashfs /tmp
        umount /boot
        
       -mount -t squashfs /tmp/filesystem.squashfs /mnt
       -mount -t tmpfs -o size=50M none /mnt/home/uwu/.electrum
       +mount -t squashfs /tmp/filesystem.squashfs /mnt/ro
       +mount -t tmpfs size=256M none /mnt/rw
       +mkdir /mnt/rw/upper /mnt/rw/work
       +mount -t overlay \
       +        -o lowerdir=/mnt/ro,upperdir=/mnt/rw/upper,workdir=/mnt/rw/work \
       +        overlay /mnt/overlay
        
       -mount --move /dev /mnt/dev
       +mount --move /dev /mnt/overlay dev
        umount /proc /sys
        
        exec /bin/sh