diff --git a/setup.sh b/setup.sh index a936017..efb533d 100644 --- a/setup.sh +++ b/setup.sh @@ -462,10 +462,10 @@ else connection="$address" fi # --content-filename=\"${hostname}.ssh.key\" --content-name=\"${hostname}.ssh.key\" -echo "(echo \"Server available at $connection \\n\`cat \"/home/${admin}/.ssh/id_rsa\"\`\" | mail -s \"$hostname SSH key\" -A \"/home/${admin}/.ssh/id_rsa\" -r \"${email}\" \"${admins}\"" >> /mnt/setup-chroot.sh +echo "serverinfo=\`cat \"/home/${admin}/.ssh/id_rsa\"\`" >> /mnt/setup-chroot.sh +echo "serverinfo=\"Server available at $connection\\n\$serverinfo\"; echo \"\$serverinfo\" | mail -s \"$hostname SSH key\" -A \"/home/${admin}/.ssh/id_rsa\" -r \"${email}\" \"${admins}\"" >> /mnt/setup-chroot.sh echo "echo \"Done.\"" >> /mnt/setup-chroot.sh -echo "exit 0" >> /mnt/setup-chroot.sh errors=`chmod +x /mnt/setup-chroot.sh 2>&1 1>/dev/null` if ! [ "$?" = "0" ]; then @@ -486,6 +486,7 @@ echo "echo \"0 0 * * 1 /zfshealth.sh\" | crontab" >> /mnt/setup-chroot.sh echo "systemctl unmask cron 2>/dev/null 1>/dev/null; systemctl enable cron 2>/dev/null 1>/dev/null" >> /mnt/setup-chroot.sh +echo "exit 0" >> /mnt/setup-chroot.sh