Update terraform/main.tf

This commit is contained in:
2026-02-15 20:59:53 +01:00
parent 2769be4286
commit d378e050d9

View File

@@ -1,10 +1,11 @@
resource "proxmox_vm_qemu" "ubuntu2404_vm" { resource "proxmox_vm_qemu" "ubuntu2404_vm" {
name = "terraform-vm" name = "terraform-vm"
target_node = "nuctyzyzen7-1" target_node = "nuctyzyzen7-1"
vmid = 9505 vmid = 9505
clone = "ubuntu-2404-ci-template" # Kloon de template
full_clone = true full_clone = true
clone = "ubuntu-2404-ci-template" # jouw werkende template
cores = 2 cores = 2
sockets = 1 sockets = 1
@@ -13,18 +14,8 @@ resource "proxmox_vm_qemu" "ubuntu2404_vm" {
machine = "q35" machine = "q35"
agent = 1 agent = 1
# Bootdisk clonen van template # Eventuele extra disk toevoegen, maar voor bootdisk hoef je niets te doen
disk { # cloud-init CD wordt automatisch aangemaakt
slot = "virtio0"
type = "disk"
storage = "zfs1"
size = "32G"
cache = "writeback"
discard = true
clone = "ubuntu-2404-ci-template/virtio0" # belangrijk!
}
# Cloud-init CD-ROM wordt automatisch toegevoegd
disk { disk {
slot = "scsi1" slot = "scsi1"
type = "cdrom" type = "cdrom"
@@ -37,7 +28,7 @@ resource "proxmox_vm_qemu" "ubuntu2404_vm" {
bridge = "vmbr0" bridge = "vmbr0"
} }
# Cloud-init instellingen # Cloud-init configuratie
os_type = "cloud-init" os_type = "cloud-init"
ciuser = "martijn" ciuser = "martijn"
cipassword = "Gwh28dgcmp!" cipassword = "Gwh28dgcmp!"