diskimage-builder/tests/elements/fake-os/root.d/10-fake-os

15 lines
346 B
Plaintext
Raw Normal View History

#!/bin/bash
set -eux
set -o pipefail
sudo touch $TARGET_ROOT/fake-os
for DIR in etc mnt proc dev sys tmp; do
sudo mkdir -p ${TARGET_ROOT}/${DIR}
done
# We need some size so the mkfs does not fail when making an fs of size 0
# We also need to account for the journal size on the FS
dd if=/dev/zero of=$TARGET_ROOT/fake-data bs=1M count=42