diff --git a/README.md b/README.md index 13c4682..0761cb5 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Cloud Init Script -This script automates the setup of a virtual machine using a cloud image in Proxmox, with options to create a template and override any existing virtual machine with the same ID. +This script automates the setup of a virtual machine using a cloud image in Proxmox, with options to create a template and override any existing virtual machine within a specified range of IDs. ## Usage @@ -8,7 +8,7 @@ You can execute this script directly using `curl` with the following commands: ### 1. **Default Storage (`proxmox`) and Default VM Name (`ubuntu-cloudinit2404`):** -To run the script using the default storage (`proxmox`) and the default VM name (`ubuntu-cloudinit2404`): +To run the script using the default storage (`proxmox`) and the default VM name (`ubuntu-cloudinit2404`), with VM IDs starting from `8000`: ```bash curl -sSL https://git.nixc.us/colin/cloud-init/raw/branch/main/install.sh | bash @@ -16,33 +16,28 @@ curl -sSL https://git.nixc.us/colin/cloud-init/raw/branch/main/install.sh | bash ### 2. **Specify a Different Storage:** -To specify a different storage (`local`) while using the default VM name (`ubuntu-cloudinit2404`): +To specify a different storage (`local`) while using the default VM name (`ubuntu-cloudinit2404`), with VM IDs starting from `8000`: ```bash curl -sSL https://git.nixc.us/colin/cloud-init/raw/branch/main/install.sh | bash -s -- local ``` -### 3. **Specify a Different Cloud Image, VM Name, and Storage:** +### 3. **Specify a Starting VM ID, Cloud Image, VM Name, and Storage:** -To specify a custom cloud image URL, image name, distribution name, version, and storage, the script expects the following parameters in order: +The script allows you to specify a starting VM ID, cloud image URL, image name, distribution name, version, and storage. The script will delete all VMs in the range starting from the specified ID up to the number of VMs being created (e.g., six VMs). -1. **Cloud Image URL**: The URL from where the cloud image will be downloaded. -2. **Image Name**: The name to save the downloaded image file. -3. **Distribution Name**: The name of the distribution (e.g., `ubuntu`, `debian`). -4. **Version**: The version of the distribution (e.g., `2404`, `11`). -5. **Storage**: The Proxmox storage location (e.g., `local`, `proxmox`). - -Example: +#### Example for Debian 11: ```bash -curl -sSL https://git.nixc.us/colin/cloud-init/raw/branch/main/install.sh | bash -s -- https://cloud-images.ubuntu.com/noble/current/noble-server-cloudimg-amd64.img noble-server-cloudimg-amd64.img ubuntu 2404 local +curl -sSL https://git.nixc.us/colin/cloud-init/raw/branch/main/install.sh | bash -s -- https://cloud.debian.org/images/cloud/bullseye/latest/debian-11-genericcloud-amd64.img debian-11-genericcloud-amd64.img debian 11 local ``` -This command does the following: -- Downloads the cloud image from `https://cloud-images.ubuntu.com/noble/current/noble-server-cloudimg-amd64.img`. -- Saves the image as `noble-server-cloudimg-amd64.img`. -- Sets the distribution name as `ubuntu` and the version as `2404`. -- Uses `local` as the Proxmox storage location. +This command will: +- Download the Debian 11 cloud image. +- Save it as `debian-11-genericcloud-amd64.img`. +- Set the distribution name as `debian` and the version as `11`. +- Use `local` as the Proxmox storage location. +- Prompt for a starting VM ID. ## Manual Template Creation