From f32faf6e99c81663f8aba6abc7789d7cb1f8f8c3 Mon Sep 17 00:00:00 2001 From: spiritLHLS <103393591+spiritLHLS@users.noreply.github.com> Date: Mon, 10 Apr 2023 15:08:57 +0800 Subject: [PATCH] Update rebuild_qcow2.sh --- back/rebuild_qcow2.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/back/rebuild_qcow2.sh b/back/rebuild_qcow2.sh index 7834496..0c28500 100644 --- a/back/rebuild_qcow2.sh +++ b/back/rebuild_qcow2.sh @@ -17,6 +17,9 @@ fi # export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 qcow_file=$1 echo "转换文件$qcow_file中......" +virt-customize -a $qcow_file --run-command "echo 'Modified from https://github.com/spiritLHLS/Images' > /etc/motd" +virt-customize -a $qcow_file --run-command "echo 'Related repo https://github.com/spiritLHLS/pve' > /etc/motd" +virt-customize -a $qcow_file --run-command "echo '--by https://t.me/spiritlhl' > /etc/motd" echo "启用SSH功能..." virt-customize -a $qcow_file --run-command "systemctl enable ssh" virt-customize -a $qcow_file --run-command "systemctl start ssh"