Add QEMU target

This commit is contained in:
maride 2024-07-09 22:31:50 +02:00
parent e9bf7f1197
commit 1bf2917513

View File

@ -18,8 +18,30 @@ source "virtualbox-iso" "arch-vbox-efi" {
output_directory = "builds/${source.name}-${source.type}" output_directory = "builds/${source.name}-${source.type}"
} }
source "qemu" "arch-qemu-efi" {
machine_type = "q35"
iso_urls = ["https://packages.oth-regensburg.de/archlinux/iso/2024.07.01/archlinux-2024.07.01-x86_64.iso"]
iso_checksum = "sha256:398dceea2d04767fbb8b61a9e824f2c8f5eacf62b2cb5006fd63321d978d48bc"
efi_boot = true
memory = "1024"
cpus = "2"
disk_size = "5000"
disk_interface = "virtio-scsi"
boot_wait = "5s"
boot_command = [
"<enter>",
"<wait30s>passwd<enter><wait>packer<enter><wait>packer<enter><wait>",
"top<enter>"
]
ssh_username = "root"
ssh_password = "packer"
shutdown_command = "echo 'packer' | sudo -S shutdown -P now"
output_directory = "builds/${source.name}-${source.type}"
format = "qcow2"
}
build { build {
sources = ["sources.virtualbox-iso.arch-vbox-efi"] sources = ["sources.virtualbox-iso.arch-vbox-efi", "sources.qemu.arch-qemu-efi"]
provisioner "file" { provisioner "file" {
source = "deliver" source = "deliver"