Update install.sh
This commit is contained in:
parent
b82a47ee52
commit
cd9eedb49c
17
install.sh
17
install.sh
|
@ -11,8 +11,6 @@ VM_NAME=${2:-ubuntu-cloudinit2404} # Default to "ubuntu-cloudinit2404", can be
|
|||
MEMORY=2048
|
||||
CORES=2
|
||||
STORAGE=${1:-proxmox} # Default to "proxmox", can be overridden by passing an argument
|
||||
CLONE_ID=135
|
||||
CLONE_NAME="yoshi"
|
||||
|
||||
# Function to check if a command failed
|
||||
check_command() {
|
||||
|
@ -71,14 +69,9 @@ echo "Adding serial console..."
|
|||
qm set $VM_ID --serial0 socket --vga serial0
|
||||
check_command "Adding serial console"
|
||||
|
||||
# Step 9: Create template
|
||||
echo "Creating template..."
|
||||
qm template $VM_ID
|
||||
check_command "Creating template"
|
||||
# Step 9: Echo template creation commands for later manual execution
|
||||
echo "Suggested command for creating a template:"
|
||||
echo "qm template $VM_ID"
|
||||
|
||||
# Step 10: Clone template
|
||||
echo "Cloning template..."
|
||||
qm clone $VM_ID $CLONE_ID --name $CLONE_NAME --full
|
||||
check_command "Cloning template"
|
||||
|
||||
echo "Script completed successfully!"
|
||||
echo "Script completed successfully! Don't forget to create the template when you're ready with:"
|
||||
echo "qm template $VM_ID"
|
||||
|
|
Loading…
Reference in New Issue