feat: added helper scripts
This commit is contained in:
parent
a030082f11
commit
e9ab7fc9d9
5 changed files with 49 additions and 0 deletions
15
prepare-rootfs.sh
Executable file
15
prepare-rootfs.sh
Executable file
|
@ -0,0 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
|
||||
tar -xf ./files/jammy-server-cloudimg-amd64-root.tar.xz -C ./files/rootfs
|
||||
sed -i "1 s,^.*$,root:\$y\$j9T\$4Sr0RCDCWboukd7UCeeWvIyH\$5bE15871.Uyzk77tFoYZqmPqOUosbB0MFWkKGq2/KI2::0:99999:7:::," ./files/rootfs/etc/shadow # password is amogus
|
||||
|
||||
echo "/dev/vda / ext4 discard,errors=remount-ro 0 1" > ./files/rootfs/etc/fstab
|
||||
echo "TimeoutStartSec=1" >> ./files/rootfs/lib/systemd/system/snapd.seeded.service
|
||||
rm ./files/rootfs/etc/systemd/system/multipath-tools.service
|
||||
rm ./files/rootfs/lib/systemd/system/multipathd.service
|
||||
|
||||
# rm -f ./files/rootfs/etc/systemd/system/network-online.target.wants/systemd-networkd-wait-online.service
|
||||
ln -sf ./files/rootfs/dev/null ./files/rootfs/etc/systemd/system/systemd-networkd-wait-online.service
|
||||
|
||||
virt-make-fs --format=qcow2 --size=2000M ./files/rootfs rootfs.qcow2
|
Loading…
Add table
Add a link
Reference in a new issue