fix: fix defaults for pve 8.x
Some checks failed
continuous-integration/drone/pr Build is failing

This commit is contained in:
Robert Kaussow 2024-01-14 17:18:58 +01:00
parent aba59ee684
commit a13ce9ce64
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
4 changed files with 19 additions and 20 deletions

View File

@ -24,7 +24,7 @@ Download the **latest** release.
### Step 2 - Download the Guest Operating Systems ISOs ### Step 2 - Download the Guest Operating Systems ISOs
1. Download the required guest operating system ISO images (e.g. `Rocky-9.0-x86_64-minimal.iso`). 1. Download the required guest operating system ISO images (e.g. `Rocky-9.3-x86_64-minimal.iso`).
2. Obtain the checksum type (e.g. `sha256`, `md5`, etc.) and checksum value for each guest operating system `.iso` image. This will be used in the build input variables. 2. Obtain the checksum type (e.g. `sha256`, `md5`, etc.) and checksum value for each guest operating system `.iso` image. This will be used in the build input variables.
3. Upload the guest operating system `.iso` images to your Proxmox server. 3. Upload the guest operating system `.iso` images to your Proxmox server.
@ -38,7 +38,7 @@ If required, modify the configuration and scripts files.
## Build ## Build
Initialize packer and start a build. Initialize packer and start a build. Packer creates a local HTTP server to provide the kickstart file for the VM. For this to work, the Proxmox server must be able to reach the host IP of the Packer host.
> **Info:** Using the force flag will automatically remove existing _templates_ with a matching name or VMID. > **Info:** Using the force flag will automatically remove existing _templates_ with a matching name or VMID.

View File

@ -3,12 +3,11 @@ vm_id = 910
vm_guest_os_keyboard = "de(nodeadkeys)" vm_guest_os_keyboard = "de(nodeadkeys)"
vm_guest_os_timezone = "Europe/Berlin" vm_guest_os_timezone = "Europe/Berlin"
vm_cloud_init = true vm_cloud_init = true
vm_cloud_init_storage_pool = "storage01"
vm_qemu_agent = true vm_qemu_agent = true
// Proxmox Settings // Proxmox Settings
proxmox_iso_pool = "local:iso" proxmox_iso_pool = "local:iso"
proxmox_iso_file = "Rocky-9.0-x86_64-minimal.iso" proxmox_iso_file = "Rocky-9.3-x86_64-minimal.iso"
proxmox_template_description = "Rocky Linux 9 Template" proxmox_template_description = "Rocky Linux 9 Template"
proxmox_template_name = "rocky-9-cloud" proxmox_template_name = "rocky-9-cloud"

View File

@ -2,7 +2,7 @@ packer {
required_version = ">= 1.8.3" required_version = ">= 1.8.3"
required_plugins { required_plugins {
proxmox = { proxmox = {
version = "1.1.2" version = "1.1.6"
source = "github.com/hashicorp/proxmox" source = "github.com/hashicorp/proxmox"
} }
} }
@ -52,7 +52,6 @@ source "proxmox-iso" "rocky-linux-9" {
disk_size = "${var.vm_disk_size}" disk_size = "${var.vm_disk_size}"
format = "${var.proxmox_storage_format}" format = "${var.proxmox_storage_format}"
storage_pool = "${var.proxmox_storage_pool}" storage_pool = "${var.proxmox_storage_pool}"
storage_pool_type = "${var.proxmox_storage_pool_type}"
type = "scsi" type = "scsi"
} }
@ -61,6 +60,7 @@ source "proxmox-iso" "rocky-linux-9" {
// Removable Media Settings // Removable Media Settings
iso_file = "${var.proxmox_iso_pool}/${var.proxmox_iso_file}" iso_file = "${var.proxmox_iso_pool}/${var.proxmox_iso_file}"
http_content = "${local.data_source_content}" http_content = "${local.data_source_content}"
http_interface = "${var.http_interface}"
// Boot and Provisioning Settings // Boot and Provisioning Settings
boot_wait = "10s" boot_wait = "10s"

View File

@ -48,12 +48,6 @@ variable "proxmox_storage_pool" {
default = "local-lvm" default = "local-lvm"
} }
variable "proxmox_storage_pool_type" {
type = string
description = "The type of the storage pool."
default = "lvm-thin"
}
variable "proxmox_template_description" { variable "proxmox_template_description" {
type = string type = string
description = "Description of the template, visible in the Proxmox interface." description = "Description of the template, visible in the Proxmox interface."
@ -110,7 +104,7 @@ variable "vm_cpu_cores" {
variable "vm_cpu_type" { variable "vm_cpu_type" {
type = string type = string
description = "The CPU type to emulate." description = "The CPU type to emulate."
default = "host" default = "x86-64-v2-AES"
} }
variable "vm_mem_size" { variable "vm_mem_size" {
@ -140,7 +134,7 @@ variable "vm_disk_thin_provisioned" {
variable "vm_network_adapter_model" { variable "vm_network_adapter_model" {
type = string type = string
description = "Model of the virtual network adapter." description = "Model of the virtual network adapter."
default = "e1000" default = "virtio"
} }
variable "vm_network_adapter_bridge" { variable "vm_network_adapter_bridge" {
@ -173,6 +167,12 @@ variable "vm_qemu_agent" {
default = false default = false
} }
variable "http_interface" {
type = string
description = "Name of the network interface that Packer gets HTTPIP from."
default = ""
}
// Communicator Settings and Credentials // Communicator Settings and Credentials
variable "build_password" { variable "build_password" {
type = string type = string