Update terraform/main.tf

This commit is contained in:
2026-02-15 20:28:21 +01:00
parent b46ee64423
commit b9ad4e8cb4

View File

@@ -1,15 +1,25 @@
resource "proxmox_vm_qemu" "vm1" { resource "proxmox_vm_qemu" "vm1" {
name = "terraform-vm" name = "terraform-vm"
target_node = "nuctyzyzen7-1" target_node = "nuctyzyzen7-1"
clone = "ubuntu-2404-ci-template" # je bestaande template
full_clone = true full_clone = true
cpu { cpu {
cores = 2 cores = 2
sockets = 1 sockets = 1
} }
memory = 2048 memory = 2048
scsihw = "virtio-scsi-pci"
machine = "q35"
# Bootdisk cloned from template
disk {
slot = "virtio0"
type = "disk"
storage = "zfs1"
size = "32G"
clone = "ubuntu-2404-ci-template/virtio0"
cache = "writeback"
discard = true
}
network { network {
id = 0 id = 0
@@ -17,11 +27,12 @@ resource "proxmox_vm_qemu" "vm1" {
bridge = "vmbr0" bridge = "vmbr0"
} }
# Cloud-init configuratie # Cloud-init
ciuser = "martijn" ciuser = "martijn"
cipassword = "Gwh28dgcmp!" cipassword = "Gwh28dgcmp!"
ipconfig0 = "ip=dhcp" ipconfig0 = "ip=dhcp"
searchdomain = "domain.local" searchdomain = "domain.local"
nameserver = "192.168.178.1" nameserver = "192.168.178.1"
agent = 1
} }