packer/Almalinux-9/almalinux-9.pkr.hcl

50 lines
1.6 KiB
HCL
Raw Normal View History

2024-04-18 11:25:21 -04:00
variable "proxmox_apiuser" {
type = string
default = "packer"
}
variable "proxmox_apitoken" {
type = string
default = "changeme"
}
source "proxmox-iso" "almalinux-9" {
template_name = "almalinux-9"
template_description = "Almalinux 9.3, generated on ${timestamp()}"
boot_wait = "5s"
2024-04-18 11:25:21 -04:00
boot_key_interval = "250ms"
boot_command = ["<tab><wait1s>", " inst.ks=http://ks.int.metaunix.net/kickstarts/almalinux-9-server.ks<enter><wait5m>"]
# shutdown_command = "echo 'packer' | sudo -S poweroff"
memory = "2048"
2024-04-18 11:25:21 -04:00
disks {
disk_size = "10G"
storage_pool = "templates"
type = "scsi"
}
network_adapters {
bridge = "vmbr0"
model = "virtio"
}
proxmox_url = "https://kamino.int.metaunix.net:8006/api2/json/"
insecure_skip_tls_verify = true
username = "${var.proxmox_apiuser}"
password = "${var.proxmox_apitoken}"
node = "geonosis"
iso_url = "https://repo.almalinux.org/almalinux/9.3/isos/x86_64/AlmaLinux-9.3-x86_64-boot.iso"
iso_checksum = "sha256:af5377a1d16bbe599ea91a8761ad645f2f54687075802bdc0c0703ee610182e9"
iso_storage_pool = "iso"
unmount_iso = true
iso_download_pve = true
ssh_username = "xadmin"
ssh_password = "packer"
ssh_timeout = "20m"
}
build {
sources = ["source.proxmox-iso.almalinux-9"]
}