packer-proxmox/rocky-9/variables.pkr.hcl

200 lines
4.8 KiB
HCL
Raw Normal View History

2022-08-06 20:17:14 +00:00
// Proxmox Settings
variable "proxmox_iso_file" {
type = string
description = "Path to the ISO file to boot from, expressed as a proxmox datastore path."
2022-08-06 20:17:14 +00:00
}
variable "proxmox_iso_pool" {
type = string
description = "Storage pool where the ISO file is stored."
default = "local:iso"
2022-08-06 20:17:14 +00:00
}
variable "proxmox_url" {
type = string
description = "URL to the Proxmox API, including the full path."
sensitive = true
default = ""
2022-08-06 20:17:14 +00:00
}
variable "proxmox_node" {
type = string
description = "Name of a node in the Proxmox cluster on which to start the virtual machine when it is created."
2022-08-06 20:17:14 +00:00
}
variable "proxmox_username" {
type = string
description = "The username must include the token id after an exclamation mark."
sensitive = true
default = ""
}
variable "proxmox_token" {
type = string
description = "Token for authenticating API calls."
sensitive = true
default = ""
2022-08-06 20:17:14 +00:00
}
variable "proxmox_storage_format" {
type = string
description = "The format of the disk."
default = "raw"
2022-08-06 20:17:14 +00:00
}
variable "proxmox_storage_pool" {
type = string
description = "Name of the Proxmox storage pool where the virtual machine hard disk will be stored."
default = "local-lvm"
2022-08-06 20:17:14 +00:00
}
variable "proxmox_template_description" {
type = string
description = "Description of the template, visible in the Proxmox interface."
2022-08-06 20:17:14 +00:00
}
variable "proxmox_template_name" {
type = string
description = "Description of the template, visible in the Proxmox interface."
2022-08-06 20:17:14 +00:00
}
// Virtual Machine Settings
variable "vm_id" {
type = number
description = "The ID used to reference the virtual machine."
default = 900
2022-08-06 20:17:14 +00:00
}
variable "vm_guest_os_language" {
type = string
description = "The guest operating system lanugage."
default = "en_US"
}
variable "vm_guest_os_keyboard" {
type = string
description = "The guest operating system keyboard input."
default = "us"
}
variable "vm_guest_os_timezone" {
type = string
description = "The guest operating system timezone."
default = "America/New_York"
}
variable "vm_os_type" {
type = string
description = "The operating system."
default = "l26"
}
variable "vm_cpu_sockets" {
type = number
description = "The number of virtual CPUs sockets."
2022-08-06 20:17:14 +00:00
default = 1
}
variable "vm_cpu_cores" {
type = number
description = "The number of virtual CPUs cores per socket."
2024-04-11 21:23:18 +00:00
default = 2
2022-08-06 20:17:14 +00:00
}
variable "vm_cpu_type" {
type = string
description = "The CPU type to emulate."
default = "x86-64-v2-AES"
2022-08-06 20:17:14 +00:00
}
variable "vm_mem_size" {
type = number
description = "The size for the virtual memory in MB."
2024-04-11 21:23:18 +00:00
default = 2048
2022-08-06 20:17:14 +00:00
}
variable "vm_disk_size" {
type = string
description = "The size for the virtual disk."
default = "20G"
2022-08-06 20:17:14 +00:00
}
variable "vm_disk_controller_type" {
type = list(string)
description = "The virtual disk controller types in sequence."
2022-08-06 20:17:14 +00:00
default = ["pvscsi"]
}
variable "vm_disk_thin_provisioned" {
type = bool
description = "Thin provision the virtual disk."
default = true
}
variable "vm_network_adapter_model" {
type = string
description = "Model of the virtual network adapter."
default = "virtio"
2022-08-06 20:17:14 +00:00
}
variable "vm_network_adapter_bridge" {
type = string
description = "Which Proxmox bridge to attach the adapter to."
default = "vmbr0"
}
variable "vm_network_adapter_vlan_tag" {
type = string
description = "If the adapter should tag packets."
default = ""
}
2022-08-10 14:01:24 +00:00
variable "vm_cloud_init" {
type = bool
description = "Add a Cloud-Init CDROM drive after the virtual machine has been converted."
default = false
}
variable "vm_cloud_init_storage_pool" {
type = string
description = "Name of the Proxmox storage pool to store the Cloud-Init CDROM on."
default = ""
}
variable "vm_qemu_agent" {
type = bool
description = "Enables QEMU Agent option for this VM."
default = false
}
variable "http_interface" {
type = string
description = "Name of the network interface that Packer gets HTTPIP from."
default = ""
}
2022-08-06 20:17:14 +00:00
// Communicator Settings and Credentials
variable "build_password" {
type = string
description = "The password to login the guest operating system."
2022-08-06 20:17:14 +00:00
sensitive = true
}
variable "build_password_encrypted" {
type = string
description = "The encrypted password to login the guest operating system."
sensitive = true
}
variable "build_scripts" {
type = list(string)
description = "A list of scripts and their relative paths to transfer and execute."
default = []
2022-08-06 20:17:14 +00:00
}
variable "communicator_timeout" {
type = string
description = "The timeout for the communicator protocol."
default = "30m"
}