From b216e9dac47ae75891616a59065d93d083873fc1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Domagoj=20Andri=C4=87?= Date: Sat, 7 Mar 2026 17:59:58 +0100 Subject: [PATCH] Realign partitioning --- ws2022/answer_files/Autounattend.xml.pkrtpl | 14 +++++++++++++- ws2022/main.pkr.hcl | 13 +++++++------ ws2022/variables.pkr.hcl | 8 +++++++- 3 files changed, 27 insertions(+), 8 deletions(-) diff --git a/ws2022/answer_files/Autounattend.xml.pkrtpl b/ws2022/answer_files/Autounattend.xml.pkrtpl index f39b646..f6c0aa0 100644 --- a/ws2022/answer_files/Autounattend.xml.pkrtpl +++ b/ws2022/answer_files/Autounattend.xml.pkrtpl @@ -55,7 +55,7 @@ versionScope="nonSxS" > - + 0 @@ -74,6 +74,11 @@ 3 Primary + ${os_partition_mb} + + + 4 + Primary true @@ -91,6 +96,13 @@ C + + 3 + 4 + NTFS + + de94bba4-06d1-4d40-a16a-bfd50179d6ac + diff --git a/ws2022/main.pkr.hcl b/ws2022/main.pkr.hcl index 2d2bf2a..a71dbeb 100644 --- a/ws2022/main.pkr.hcl +++ b/ws2022/main.pkr.hcl @@ -64,12 +64,13 @@ source "proxmox-iso" "ws2022" { additional_iso_files { cd_content = { "Autounattend.xml" = templatefile("answer_files/Autounattend.xml.pkrtpl", { - admin_password = var.admin_password - image_index = var.image_index - product_key = var.product_key - locale = var.locale - timezone = var.timezone - virtio_drive = var.virtio_drive_letter + admin_password = var.admin_password + image_index = var.image_index + product_key = var.product_key + locale = var.locale + timezone = var.timezone + virtio_drive = var.virtio_drive_letter + os_partition_mb = var.os_partition_mb }) } cd_label = "OEMDRV" diff --git a/ws2022/variables.pkr.hcl b/ws2022/variables.pkr.hcl index 921d3cf..13b7195 100644 --- a/ws2022/variables.pkr.hcl +++ b/ws2022/variables.pkr.hcl @@ -47,7 +47,13 @@ variable "vm_cores" { variable "disk_size" { type = string - default = "60G" + default = "80G" +} + +variable "os_partition_mb" { + type = number + default = 80692 + description = "OS (C:) partition size in MB. Formula: (disk_size_MB - 100 EFI - 128 MSR - 1000 Recovery). Default matches 80G disk." } variable "network_bridge" {