From 48109b672dad7599d62c9771d22ce5711274e04e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Mach?= Date: Wed, 2 Mar 2022 15:49:58 +0100 Subject: [PATCH] Fix debian osdisk size --- templates/debian-11/debian-11.pkr.hcl | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/templates/debian-11/debian-11.pkr.hcl b/templates/debian-11/debian-11.pkr.hcl index 0d5ee32..ece3058 100644 --- a/templates/debian-11/debian-11.pkr.hcl +++ b/templates/debian-11/debian-11.pkr.hcl @@ -49,10 +49,9 @@ variable "iso_path" { default = "" } - -variable "iso_checksum" { - type = string - default = "" +variable "osdisk_size" { + type = number + default = 20480 } locals { @@ -80,7 +79,7 @@ source "hyperv-iso" "debian-11" { switch_name = "${var.switch_name}" vm_name = "packer-${var.vm_name}" differencing_disk = true - disk_size = 20480 #20GB + disk_size = "${var.osdisk_size}" disk_block_size = 1 # 1MB as per https://docs.microsoft.com/en-us/windows-server/virtualization/hyper-v/best-practices-for-running-linux-on-hyper-v#tuning-linux-file-systems-on-dynamic-vhdx-files }